Skip to content

Commit

Permalink
fix(billing): fixed redirection to hosting mx plan resiliation page (#…
Browse files Browse the repository at this point in the history
…14820)

ref: MANAGER-16668

Signed-off-by: Jacques Larique <[email protected]>
  • Loading branch information
JacquesLarique authored Jan 10, 2025
1 parent 5eec2a0 commit 2ddef16
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,15 @@ export default /* @ngInject */ ($stateProvider, $urlRouterProvider) => {
email: /* @ngInject */ (BillingAutoRenew, name) =>
BillingAutoRenew.getEmailInfos(name),
isHosting: /* @ngInject */ (email) => /hosting/.test(email.offer),
redirection: /* @ngInject */ ($q, isHosting, email) => {
redirection: /* @ngInject */ ($q, coreURLBuilder, isHosting, email) => {
if (isHosting) {
window.location.href = `/web/#/hosting/${encodeURIComponent(
email.domain,
)}/terminateEmail?tab=GENERAL_INFORMATIONS`;
window.location.href = coreURLBuilder.buildURL(
'web',
`#/hosting/${encodeURIComponent(email.domain)}/terminateEmail`,
{
tab: 'GENERAL_INFORMATIONS',
},
);
return $q.defer().promise;
}
return $q.when();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,15 @@ export default /* @ngInject */ ($stateProvider, $urlRouterProvider) => {
email: /* @ngInject */ (BillingAutoRenew, name) =>
BillingAutoRenew.getEmailInfos(name),
isHosting: /* @ngInject */ (email) => /hosting/.test(email.offer),
redirection: /* @ngInject */ ($q, isHosting, email) => {
redirection: /* @ngInject */ ($q, coreURLBuilder, isHosting, email) => {
if (isHosting) {
window.location.href = `/web/#/hosting/${encodeURIComponent(
email.domain,
)}/terminateEmail?tab=GENERAL_INFORMATIONS`;
window.location.href = coreURLBuilder.buildURL(
'web',
`#/hosting/${encodeURIComponent(email.domain)}/terminateEmail`,
{
tab: 'GENERAL_INFORMATIONS',
},
);
return $q.defer().promise;
}
return $q.when();
Expand Down

0 comments on commit 2ddef16

Please sign in to comment.