-
+
@@ -65,6 +66,7 @@
diff --git a/src/mixins/base-mixin.js b/src/mixins/base-mixin.js
index ff9655ab..bd2d0807 100644
--- a/src/mixins/base-mixin.js
+++ b/src/mixins/base-mixin.js
@@ -14,6 +14,7 @@ export default {
},
methods: {
setCmsContent(cmsContent) {
+ console.log(' setting cms content');
this.$root.cmsContentByWidget = cmsContent;
},
getCmsContent(widgetName, fieldName) {
diff --git a/src/router/index.js b/src/router/index.js
index ca1609f9..1b5de854 100644
--- a/src/router/index.js
+++ b/src/router/index.js
@@ -52,6 +52,7 @@ const routes = [
// Process ISS cookie.
updateOrCreateISSCookie();
+ // TODO check prerequisite stuff in here
if (router.hasRoute(issPageToUse)) {
// Since our route is already in scope, we can grab the component and call the arePagePrerequisitesValid function.
let component = router.getRoutes().filter((x) => x.name === issPageToUse)[0].components;
@@ -216,6 +217,7 @@ function navigate(
optionalParams = {},
optionalPageData = {}
) {
+ console.log('entering navigate');
/*eslint-disable-line*/
if (!scenario) {
window.console.error('No scenario provided. Please review the routing table.');
@@ -230,12 +232,15 @@ function navigate(
return;
}
+ console.log('entering navigate');
if (scenario === navigationScenarios.CLICKED_BACK_PREVIOUS) {
// Update page to the prevous page in the router.
// If we need to worry about typing this in from outside of the app,
// we'll need to pre check history.length or if there is a previous page stored in state.
router.go(-1);
} else if (matchingScenarioMap.destinationIssPageValue) {
+ console.log(matchingScenarioMap);
+ console.log('else if 1');
// Update page data to the store for next page if provided. Otherwise, keep existing page data or set to empty object
const existingPageDataForPage = useMainStore().pageData(matchingScenarioMap.destinationIssPageValue);
baseMixin.methods.savePageDataToStore(
@@ -255,6 +260,8 @@ function navigate(
params: optionalParams
});
} else if (matchingScenarioMap.destinationUrl) {
+ console.log(matchingScenarioMap.destinationUrl);
+ console.log('else if 2');
navigateToUrl(matchingScenarioMap.destinationUrl, optionalQuery);
}
}
diff --git a/src/router/router-constants/navigation-scenarios.js b/src/router/router-constants/navigation-scenarios.js
index 1c6c1a13..69c61090 100644
--- a/src/router/router-constants/navigation-scenarios.js
+++ b/src/router/router-constants/navigation-scenarios.js
@@ -63,6 +63,9 @@ const navigationScenarios = Object.freeze({
CLICKED_BACK_WITH_REPAIR: 'CLICKED_BACK_WITH_REPAIR',
CLICKED_FORWARD_WITH_INVALID_STATE: 'CLICKED_FORWARD_WITH_INVALID_STATE',
+ // TPA Search
+ CLICKED_DO_NOT_SEE_MY_SHOP_LINK: 'CLICKED_DO_NOT_SEE_MY_SHOP_LINK',
+
// Provider Preference
CLICKED_FORWARD_WITH_SAFELITE: 'CLICKED_FORWARD_WITH_SAFELITE',
CLICKED_FORWARD_WITH_TPA_ENABLED: 'CLICKED_FORWARD_WITH_TPA_ENABLED',
diff --git a/src/router/router-constants/routing-table.js b/src/router/router-constants/routing-table.js
index 9ee532d5..eebf8437 100644
--- a/src/router/router-constants/routing-table.js
+++ b/src/router/router-constants/routing-table.js
@@ -666,6 +666,10 @@ const routingTable = () => [
{
scenario: navigationScenarios.CLICKED_FORWARD,
destinationIssPageValue: issPageValues.TPA_SUBMIT
+ },
+ {
+ scenario: navigationScenarios.CLICKED_DO_NOT_SEE_MY_SHOP_LINK,
+ destinationIssPageValue: issPageValues.BAILOUT_PAGE
}
]
},
diff --git a/src/store/index.js b/src/store/index.js
index 60699f03..e5e7868c 100644
--- a/src/store/index.js
+++ b/src/store/index.js
@@ -799,6 +799,26 @@ export const useMainStore = defineStore({
});
},
+ // TODO what info is returned here
+ getTpaProviders(zipCode, radius) {
+ return {
+ data: [
+ // {
+ // buttonLabel: 'USA Auto Glass',
+ // buttonLabelSubCopy: '1.5 mi',
+ // buttonBodyCopy: '760 Dearborn Park Ln, Worthington, OH 43085
614-123-5555',
+ // value: '000123'
+ // },
+ {
+ buttonLabel: 'USA Auto Glass',
+ buttonLabelSubCopy: '1.5 mi',
+ buttonBodyCopy: '760 Dearborn Park Ln, Worthington, OH 43085
614-123-5555',
+ value: '000123'
+ }
+ ]
+ };
+ },
+
async getSupportingItems() {
const glassPartsArray = this.order.lineItems.glassParts ?? [];
const { carId } = this.order.vehicle;
@@ -980,7 +1000,7 @@ export const useMainStore = defineStore({
streetAddress2: customer.address?.streetAddress2,
city: customer.address?.city,
state: customer.address?.state,
- zipCode: customer.address?.zipCode
+ zipCode: customer.address?.zipCode?.toString()
},
emailAddress: contactInfo.emailAddress,
firstName: contactInfo.firstName || customer.firstName,