CSR-1852 updated to use page constants
This commit is contained in:
parent
44a6218328
commit
393ce3df4d
1 changed files with 3 additions and 2 deletions
|
|
@ -171,12 +171,13 @@ router.beforeEach(async (to, from, next) => {
|
|||
}
|
||||
|
||||
const toQueryPage = to.query?.fmgPage;
|
||||
const notToPIAReturn = toQueryPage != "payment-pia-return";
|
||||
const notToPIAReturn = toQueryPage != fmgPageValues.PAYMENT_PIA_RETURN;
|
||||
const isInIframe = window !== window.top;
|
||||
|
||||
// fromPaymentToConfirmation workaround for navigating from an iframe but
|
||||
// isInIframe evaluates to false for some reason when navigating from payment to confirmation
|
||||
const fromPaymentToConfirmation = fromQueryPage === "payment" && toQueryPage === "confirmation";
|
||||
const fromPaymentToConfirmation =
|
||||
fromQueryPage === fmgPageValues.PAYMENT && toQueryPage === fmgPageValues.CONFIRMATION;
|
||||
|
||||
if ((isInIframe && notToPIAReturn) || fromPaymentToConfirmation) {
|
||||
const newUrl = `${window.top.location.origin}${to.href}`;
|
||||
|
|
|
|||
Loading…
Reference in a new issue