From 35c7cc8ec1db65364c5fbfd003b7bc09e4118d94 Mon Sep 17 00:00:00 2001 From: Michael Klein Date: Wed, 12 Oct 2022 10:36:25 +0200 Subject: [PATCH] Rename `peers.edit` to `peers.show` --- .../app/components/consul/peer/list/index.hbs | 4 ++-- .../app/controllers/dc/peers/{edit => show}/exported.js | 0 .../app/controllers/dc/peers/{edit => show}/index.js | 2 +- .../app/templates/dc/peers/{edit.hbs => show.hbs} | 0 .../app/templates/dc/peers/{edit => show}/addresses.hbs | 0 .../app/templates/dc/peers/{edit => show}/exported.hbs | 0 .../app/templates/dc/peers/{edit => show}/imported.hbs | 0 .../app/templates/dc/peers/{edit => show}/index.hbs | 0 .../consul-peerings/vendor/consul-peerings/routes.js | 2 +- .../consul-ui/app/components/peerings/provider/index.js | 6 +++--- 10 files changed, 7 insertions(+), 7 deletions(-) rename ui/packages/consul-peerings/app/controllers/dc/peers/{edit => show}/exported.js (100%) rename ui/packages/consul-peerings/app/controllers/dc/peers/{edit => show}/index.js (82%) rename ui/packages/consul-peerings/app/templates/dc/peers/{edit.hbs => show.hbs} (100%) rename ui/packages/consul-peerings/app/templates/dc/peers/{edit => show}/addresses.hbs (100%) rename ui/packages/consul-peerings/app/templates/dc/peers/{edit => show}/exported.hbs (100%) rename ui/packages/consul-peerings/app/templates/dc/peers/{edit => show}/imported.hbs (100%) rename ui/packages/consul-peerings/app/templates/dc/peers/{edit => show}/index.hbs (100%) diff --git a/ui/packages/consul-peerings/app/components/consul/peer/list/index.hbs b/ui/packages/consul-peerings/app/components/consul/peer/list/index.hbs index 993bd93d20..886dfc8d20 100644 --- a/ui/packages/consul-peerings/app/components/consul/peer/list/index.hbs +++ b/ui/packages/consul-peerings/app/components/consul/peer/list/index.hbs @@ -9,7 +9,7 @@ {{#if (can "delete peer" item=item)}} {{item.Name}} @@ -60,7 +60,7 @@ {{/if}} View diff --git a/ui/packages/consul-peerings/app/controllers/dc/peers/edit/exported.js b/ui/packages/consul-peerings/app/controllers/dc/peers/show/exported.js similarity index 100% rename from ui/packages/consul-peerings/app/controllers/dc/peers/edit/exported.js rename to ui/packages/consul-peerings/app/controllers/dc/peers/show/exported.js diff --git a/ui/packages/consul-peerings/app/controllers/dc/peers/edit/index.js b/ui/packages/consul-peerings/app/controllers/dc/peers/show/index.js similarity index 82% rename from ui/packages/consul-peerings/app/controllers/dc/peers/edit/index.js rename to ui/packages/consul-peerings/app/controllers/dc/peers/show/index.js index 0f4af5e828..1c63d8407d 100644 --- a/ui/packages/consul-peerings/app/controllers/dc/peers/edit/index.js +++ b/ui/packages/consul-peerings/app/controllers/dc/peers/show/index.js @@ -6,6 +6,6 @@ export default class DcPeersEditIndexController extends Controller { @service router; @action transitionToImported() { - this.router.replaceWith("dc.peers.edit.imported"); + this.router.replaceWith("dc.peers.show.imported"); } } diff --git a/ui/packages/consul-peerings/app/templates/dc/peers/edit.hbs b/ui/packages/consul-peerings/app/templates/dc/peers/show.hbs similarity index 100% rename from ui/packages/consul-peerings/app/templates/dc/peers/edit.hbs rename to ui/packages/consul-peerings/app/templates/dc/peers/show.hbs diff --git a/ui/packages/consul-peerings/app/templates/dc/peers/edit/addresses.hbs b/ui/packages/consul-peerings/app/templates/dc/peers/show/addresses.hbs similarity index 100% rename from ui/packages/consul-peerings/app/templates/dc/peers/edit/addresses.hbs rename to ui/packages/consul-peerings/app/templates/dc/peers/show/addresses.hbs diff --git a/ui/packages/consul-peerings/app/templates/dc/peers/edit/exported.hbs b/ui/packages/consul-peerings/app/templates/dc/peers/show/exported.hbs similarity index 100% rename from ui/packages/consul-peerings/app/templates/dc/peers/edit/exported.hbs rename to ui/packages/consul-peerings/app/templates/dc/peers/show/exported.hbs diff --git a/ui/packages/consul-peerings/app/templates/dc/peers/edit/imported.hbs b/ui/packages/consul-peerings/app/templates/dc/peers/show/imported.hbs similarity index 100% rename from ui/packages/consul-peerings/app/templates/dc/peers/edit/imported.hbs rename to ui/packages/consul-peerings/app/templates/dc/peers/show/imported.hbs diff --git a/ui/packages/consul-peerings/app/templates/dc/peers/edit/index.hbs b/ui/packages/consul-peerings/app/templates/dc/peers/show/index.hbs similarity index 100% rename from ui/packages/consul-peerings/app/templates/dc/peers/edit/index.hbs rename to ui/packages/consul-peerings/app/templates/dc/peers/show/index.hbs diff --git a/ui/packages/consul-peerings/vendor/consul-peerings/routes.js b/ui/packages/consul-peerings/vendor/consul-peerings/routes.js index 4357c60be5..1f8675c1c3 100644 --- a/ui/packages/consul-peerings/vendor/consul-peerings/routes.js +++ b/ui/packages/consul-peerings/vendor/consul-peerings/routes.js @@ -22,7 +22,7 @@ }, }, }, - edit: { + show: { _options: { path: "/:name", }, diff --git a/ui/packages/consul-ui/app/components/peerings/provider/index.js b/ui/packages/consul-ui/app/components/peerings/provider/index.js index aed351336d..23bd99d9b1 100644 --- a/ui/packages/consul-ui/app/components/peerings/provider/index.js +++ b/ui/packages/consul-ui/app/components/peerings/provider/index.js @@ -22,18 +22,18 @@ export default class PeeringsProvider extends Component { let tabs = [ { label: 'Imported Services', - route: 'dc.peers.edit.imported', + route: 'dc.peers.show.imported', tooltip: this.intl.t('routes.dc.peers.index.detail.imported.tab-tooltip', { name }), }, { label: 'Exported Services', - route: 'dc.peers.edit.exported', + route: 'dc.peers.show.exported', tooltip: this.intl.t('routes.dc.peers.index.detail.exported.tab-tooltip', { name }), }, ]; if (isReceiver) { - tabs = [...tabs, { label: 'Addresses', route: 'dc.peers.edit.addresses' }]; + tabs = [...tabs, { label: 'Addresses', route: 'dc.peers.show.addresses' }]; } return tabs.map((tab) => new Tab({ ...tab, currentRouteName: router.currentRouteName, owner }));