From 7d3ec11f5967153b59e34aab1261e701cd0fdead Mon Sep 17 00:00:00 2001 From: valeriia-ruban Date: Wed, 14 Feb 2024 19:47:39 +0000 Subject: [PATCH 1/3] backport of commit 214abc386b7a4e3b738552c1e3d05a73409c2461 --- .../app/components/hcp-nav-item/index.js | 1 - .../components/link-to-hcp-banner/index.js | 1 - .../components/link-to-hcp-modal/index.hbs | 2 +- .../app/helpers/hcp-authentication-link.js | 11 ++---- .../consul-ui/app/services/hcp-link-modal.js | 4 --- .../tests/acceptance/link-to-hcp-test.js | 11 ------ .../helpers/hcp-authentication-link-test.js | 36 +++++-------------- 7 files changed, 12 insertions(+), 54 deletions(-) diff --git a/ui/packages/consul-ui/app/components/hcp-nav-item/index.js b/ui/packages/consul-ui/app/components/hcp-nav-item/index.js index 1de939d3561f..741de542de77 100644 --- a/ui/packages/consul-ui/app/components/hcp-nav-item/index.js +++ b/ui/packages/consul-ui/app/components/hcp-nav-item/index.js @@ -52,7 +52,6 @@ export default class HcpLinkItemComponent extends Component { @action onLinkToConsulCentral() { - this.hcpLinkModal.setResourceId(this.args.linkData?.resourceId); this.hcpLinkModal.show(); } } diff --git a/ui/packages/consul-ui/app/components/link-to-hcp-banner/index.js b/ui/packages/consul-ui/app/components/link-to-hcp-banner/index.js index 3f96ac261f0e..22574aed52ab 100644 --- a/ui/packages/consul-ui/app/components/link-to-hcp-banner/index.js +++ b/ui/packages/consul-ui/app/components/link-to-hcp-banner/index.js @@ -22,7 +22,6 @@ export default class LinkToHcpBannerComponent extends Component { } @action onClusterLink() { - this.hcpLinkModal.setResourceId(this.args.linkData?.resourceId); this.hcpLinkModal.show(); } } diff --git a/ui/packages/consul-ui/app/components/link-to-hcp-modal/index.hbs b/ui/packages/consul-ui/app/components/link-to-hcp-modal/index.hbs index bdabe3b2e52e..eda5204a1007 100644 --- a/ui/packages/consul-ui/app/components/link-to-hcp-modal/index.hbs +++ b/ui/packages/consul-ui/app/components/link-to-hcp-modal/index.hbs @@ -97,7 +97,7 @@ @icon="external-link" @iconPosition="trailing" data-test-link-to-hcp-modal-next-button - @href={{hcp-authentication-link this.hcpLinkModal.resourceId this.accessLevel}} + @href={{hcp-authentication-link @dc this.accessLevel}} /> Date: Thu, 15 Feb 2024 04:45:51 +0000 Subject: [PATCH 2/3] backport of commit 6bbcc993a42f94a2184b3b3a427a650e4cc1e981 --- .../consul-ui/app/components/link-to-hcp-modal/index.hbs | 4 ++-- ui/packages/consul-ui/app/helpers/hcp-authentication-link.js | 4 ---- ui/packages/consul-ui/app/services/hcp-link-modal.js | 2 +- ui/packages/consul-ui/tests/acceptance/link-to-hcp-test.js | 3 +++ .../tests/integration/components/link-to-hcp-modal-test.js | 3 --- 5 files changed, 6 insertions(+), 10 deletions(-) diff --git a/ui/packages/consul-ui/app/components/link-to-hcp-modal/index.hbs b/ui/packages/consul-ui/app/components/link-to-hcp-modal/index.hbs index eda5204a1007..bcb6d53e49b4 100644 --- a/ui/packages/consul-ui/app/components/link-to-hcp-modal/index.hbs +++ b/ui/packages/consul-ui/app/components/link-to-hcp-modal/index.hbs @@ -45,7 +45,7 @@ {{#if (and this.isReadOnlyAccessLevelSelected (can "read acls") (can "create tokens"))}}