Skip to content

Feat/epinio 518 521 advanced configurations#561

Merged
Hannahbird merged 11 commits intofeat/EPINIO-523-524__services_catalogfrom
feat/EPINIO-518-521__advanced_configurations
Apr 14, 2026
Merged

Feat/epinio 518 521 advanced configurations#561
Hannahbird merged 11 commits intofeat/EPINIO-523-524__services_catalogfrom
feat/EPINIO-518-521__advanced_configurations

Conversation

@Hannahbird
Copy link
Copy Markdown
Contributor

@Hannahbird Hannahbird commented Apr 7, 2026

PR Checklist

  • Linting Test is passing
  • Code is well documented
  • If applicable, a PR in the epinio/docs repository has been opened

Summary

Fixes #518, #519, #520, #521

Migrates the Advanced Configurations list to trailhand-table and introduces a ConfigurationModal component that handles view, create, and edit flows in a single modal, following the same pattern established for services.

Occurred changes and/or fixed issues

  • Configurations list (list/configurations.vue): replaced Rancher shell table and create-page routing with trailhand-table + ConfigurationModal. Name column is now a clickable link that opens the view modal. Responsive column hiding at breakpoints. Action menu wired to modal edit flow.
  • ConfigurationModal (components/configuration/ConfigurationModal.vue): new component supporting view, edit, and create modes.
    • View mode: read-only, shows Namespace, Name, Bound Applications, and Config Data. "Edit Configuration" button only shown for type === 'custom' configurations.
    • Edit mode: Bound Applications and Config Data are editable. Unsaved changes trigger a discard confirmation on close.
    • Create mode: Namespace dropdown, Name input, optional Bind to Application, and Config Data key/value rows with per-row file upload (Upload) and bulk file import (Read From File). Save is disabled until all key/value pairs are fully filled.
  • App binding fix: bound/unbound app lists are now captured into local variables before closeModal() is called, preventing a cleared-ref race that silently dropped all binding changes.
  • Namespace filter fix (list/configurations.vue, list/services.vue): both tables now respect the active namespace filter via store.state.activeNamespaceCache, consistent with the applications table.
  • Configuration delete modal (components/configuration/ConfigurationDeleteModal.vue): new modal triggered from the action menu Delete item (gated to type === 'custom'). Displays the configuration name and lists any bound applications with a caution warning. Unbinds all bound apps before calling remove, then force-refreshes configurations and apps on success.

Technical notes summary

  • ConfigurationModal exposes openCreate, openView, and openEdit. openEdit delegates to openView then overrides modalMode to avoid duplicating hydration logic.
  • Config data is stored as Array<{ key, value }> internally and converted to/from the API's Record<string, string> via detailsToRows / rowsToDetails.
  • The update call sends { data: { ...this.data } } (PUT) as required by ConfigurationReplaceRequest. The prior implementation was missing the outer data wrapper which caused updates to silently wipe all config data.
  • void store.state.activeNamespaceCacheKey establishes Vue reactivity on the cache key inside watchEffect without introducing an unused variable.
  • Edit access is gated on configuration.type === 'custom' (both action menu and modal footer button) to prevent editing service-owned configurations.

Areas or cases that should be tested

  • Create: open modal via Create button, fill Namespace + Name + at least one key/value row, optionally bind an app, submit - verify configuration appears in the list and binding is reflected on the app.
  • Create validation: confirm Save/Create button remains disabled until Namespace, Name, and all key/value rows are fully populated.
  • Create - Read From File: upload a KEY=VALUE file and verify rows are parsed and appended correctly.
  • Create - per-row Upload: click Upload on a value cell, select a file, verify file contents populate that value.
  • View: click a linkified name - verify modal opens read-only with correct Namespace, Name, Bound Applications, and Config Data. Verify "Edit Configuration" is absent for service-owned configurations (type !== 'custom').
  • Edit via modal: open view, click Edit Configuration, modify Bound Applications and/or Config Data, save - verify changes persist.
  • Edit via action menu: use the action menu Edit item - verify it opens directly in edit mode. Confirm the action is disabled for non-custom configurations.
  • Edit - discard confirm: make a change, click Cancel/X - verify discard confirmation appears and choosing Discard closes without saving.
  • App binding: bind and unbind applications in both create and edit flows - verify the app's configuration list updates accordingly.
  • Namespace filter: change the namespace filter in the header - verify both the Configurations and Services tables update to show only resources in the selected namespace(s).
  • Delete: open the action menu on a custom configuration and select Delete - verify the modal appears with the correct name and bound app list. Confirm deletion unbinds apps and removes the configuration from the list.
  • Delete - no bound apps: verify the modal shows "No applications are bound to this configuration" when none are bound.
  • Delete - non-custom: verify the Delete action is absent from the action menu for service-owned configurations.

Areas which could experience regressions

  • Services list: the namespace filter change touches list/services.vue - verify service rows still display correctly, including state tags, action menu (edit/delete), and the delete modal flow.
  • Configurations list: the trailhand-table column formatter for Name replaces the previous link: property - verify sorting on the Name column still works.
  • App binding on configurations: the bindConfigurations / unbindConfiguration calls go through the app model - verify bound configs are reflected correctly on the application detail page.
  • App configurations: unbinding via delete goes through app.unbindConfiguration - verify the app's bound configuration list reflects the removal correctly.

Screenshot/Video

Hannahbird and others added 5 commits March 26, 2026 10:09
… support

Adds state, mutations, getters, and actions to the epinio store to support
optional server-side pagination — ready to wire up once the trailhand-table
page-change event is available.
Update data structure in configurations.js
Replace the configurations list's Rancher shell routing with a
trailhand-table and a ConfigurationModal component supporting view,
create, and edit modes. Edit is gated to configurations with
type === 'custom'. Bind-to-application changes are captured before
modal close to prevent cleared-ref race. Namespace filter now applied
to both configurations and services tables via activeNamespaceCache.
@Hannahbird Hannahbird changed the base branch from main to feat/EPINIO-523-524__services_catalog April 7, 2026 19:55
Introduce ConfigurationDeleteModal that mirrors the services delete
pattern. Lists bound applications with a caution warning, unbinds them
all before deletion, and refreshes configurations and apps on success.
Delete action in the action menu is gated to type === 'custom'.
@Hannahbird Hannahbird requested a review from johnlcos April 7, 2026 20:04
@dcharles525 dcharles525 self-requested a review April 13, 2026 18:19
Copy link
Copy Markdown
Member

@dcharles525 dcharles525 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only thing I found is when I upload a file, it adds x rows, below the initial empty row, it would be nice for the data to start in the empty row.

… the user uploads a file, the parsed rows now replace that empty row rather than being appended after it. If there are already real rows present, the uploaded rows still append as before.
@Hannahbird Hannahbird requested a review from dcharles525 April 13, 2026 20:18
Comment thread dashboard/pkg/epinio/components/configuration/ConfigurationModal.vue Outdated
Comment thread dashboard/pkg/epinio/components/configuration/ConfigurationModal.vue Outdated
Copy link
Copy Markdown
Member

@dcharles525 dcharles525 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Hannahbird Hannahbird requested a review from johnlcos April 14, 2026 15:05
Copy link
Copy Markdown
Collaborator

@johnlcos johnlcos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Hannahbird Hannahbird merged commit 2b211c1 into feat/EPINIO-523-524__services_catalog Apr 14, 2026
2 checks passed
@Hannahbird Hannahbird deleted the feat/EPINIO-518-521__advanced_configurations branch April 14, 2026 20:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants