comments
This commit is contained in:
parent
e721d0deca
commit
2ab39d9ecf
1 changed files with 10 additions and 0 deletions
|
|
@ -55,6 +55,9 @@ export async function navigateToHeritageFunnel() {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
Logic for getting the last "valid" page a user visited.
|
||||||
|
*/
|
||||||
async function getLatestPageForRedirection() {
|
async function getLatestPageForRedirection() {
|
||||||
// If this is a non-CTA navigation, determine where to send the user based on page prerequisites.
|
// If this is a non-CTA navigation, determine where to send the user based on page prerequisites.
|
||||||
// This also works if a user has a 'fmg' start_type query string but no current order.
|
// This also works if a user has a 'fmg' start_type query string but no current order.
|
||||||
|
|
@ -84,6 +87,10 @@ async function getLatestPageForRedirection() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
Overrides functionality to go to the YMMS pages in certain cases.
|
||||||
|
If this is not one of the cases, it returns the default page value passed in.
|
||||||
|
*/
|
||||||
function overrideYmmsDirectionIfNeeded(toRoute, defaultPageValue) {
|
function overrideYmmsDirectionIfNeeded(toRoute, defaultPageValue) {
|
||||||
if (store.getters.payment.insuranceCoverage.isVerified) {
|
if (store.getters.payment.insuranceCoverage.isVerified) {
|
||||||
switch (toRoute.query[queryStrings.FMG_PAGE]) {
|
switch (toRoute.query[queryStrings.FMG_PAGE]) {
|
||||||
|
|
@ -103,6 +110,9 @@ function overrideYmmsDirectionIfNeeded(toRoute, defaultPageValue) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
Determine if the page is a vin related page.
|
||||||
|
*/
|
||||||
function isVinRelatedPage(toRoute) {
|
function isVinRelatedPage(toRoute) {
|
||||||
return toRoute.query[queryStrings.FMG_PAGE] === fmgPageValues.VIN_LOOKUP ||
|
return toRoute.query[queryStrings.FMG_PAGE] === fmgPageValues.VIN_LOOKUP ||
|
||||||
toRoute.query[queryStrings.FMG_PAGE] === fmgPageValues.LICENSE_PLATE_LOOKUP ||
|
toRoute.query[queryStrings.FMG_PAGE] === fmgPageValues.LICENSE_PLATE_LOOKUP ||
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue