WIP
This commit is contained in:
parent
f0957a9bba
commit
7d0e2513be
3 changed files with 20 additions and 18 deletions
|
|
@ -70,8 +70,6 @@ export default {
|
||||||
handler(newValue) {
|
handler(newValue) {
|
||||||
if (newValue) {
|
if (newValue) {
|
||||||
this.selectedValues = "Mobile";
|
this.selectedValues = "Mobile";
|
||||||
} else {
|
|
||||||
this.selectedValues = null;
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -71,7 +71,7 @@
|
||||||
:isDropoff="isDropoff"
|
:isDropoff="isDropoff"
|
||||||
:serviceZipCode="zipCode"
|
:serviceZipCode="zipCode"
|
||||||
:selectedAppointmentType="selectedAppointmentType"
|
:selectedAppointmentType="selectedAppointmentType"
|
||||||
:shopQuestionInitialData="shopQuestionInitialData"
|
:shopQuestionData="shopQuestionData"
|
||||||
cmsWidgetName="ShopQuestionWidget" />
|
cmsWidgetName="ShopQuestionWidget" />
|
||||||
<contentGroupModal ref="RecalModal" cmsWidgetName="RecalModal" />
|
<contentGroupModal ref="RecalModal" cmsWidgetName="RecalModal" />
|
||||||
<funnel-footer
|
<funnel-footer
|
||||||
|
|
@ -145,9 +145,9 @@ export default {
|
||||||
isRecalibrationServiceableMobile: null,
|
isRecalibrationServiceableMobile: null,
|
||||||
mobileFeePart: null,
|
mobileFeePart: null,
|
||||||
zipContainsMilitaryBase: false,
|
zipContainsMilitaryBase: false,
|
||||||
selectedAppointmentType: "",
|
selectedAppointmentType: "Dropoff",
|
||||||
providerNumber: null,
|
providerNumber: null,
|
||||||
shopQuestionInitialData: null,
|
shopQuestionData: null,
|
||||||
selectedShop: "",
|
selectedShop: "",
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
|
@ -162,7 +162,7 @@ export default {
|
||||||
|
|
||||||
const mobileFeePartPromise = getPricedMobileFeePart(serviceZipCode);
|
const mobileFeePartPromise = getPricedMobileFeePart(serviceZipCode);
|
||||||
|
|
||||||
const shopQuestionInitialDataPromise = shopQuestion.methods.loadInitialData();
|
const shopQuestionDataPromise = shopQuestion.methods.loadData();
|
||||||
|
|
||||||
// Settle promises and get results
|
// Settle promises and get results
|
||||||
const promiseResultMap = [
|
const promiseResultMap = [
|
||||||
|
|
@ -183,8 +183,8 @@ export default {
|
||||||
promise: getZipCodeData,
|
promise: getZipCodeData,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
resultKey: "shopQuestionInitialData",
|
resultKey: "shopQuestionData",
|
||||||
promise: shopQuestionInitialDataPromise,
|
promise: shopQuestionDataPromise,
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
@ -197,7 +197,7 @@ export default {
|
||||||
resultMap.zipCodeData,
|
resultMap.zipCodeData,
|
||||||
resultMap.serviceabilityDetails,
|
resultMap.serviceabilityDetails,
|
||||||
resultMap.mobileFeePart,
|
resultMap.mobileFeePart,
|
||||||
resultMap.shopQuestionInitialData
|
resultMap.shopQuestionData
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
@ -308,7 +308,7 @@ export default {
|
||||||
store.getters.payment.isInsurance !== null
|
store.getters.payment.isInsurance !== null
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
setData(zipCodeData, serviceabilityDetails, mobileFeePart, shopQuestionInitialData) {
|
setData(zipCodeData, serviceabilityDetails, mobileFeePart, shopQuestionData) {
|
||||||
if (zipCodeData) {
|
if (zipCodeData) {
|
||||||
this.zipContainsMilitaryBase = zipCodeData.containsMilitaryBase;
|
this.zipContainsMilitaryBase = zipCodeData.containsMilitaryBase;
|
||||||
}
|
}
|
||||||
|
|
@ -321,8 +321,8 @@ export default {
|
||||||
this.mobileFeePart = mobileFeePart;
|
this.mobileFeePart = mobileFeePart;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (shopQuestionInitialData) {
|
if (shopQuestionData) {
|
||||||
this.shopQuestionInitialData = shopQuestionInitialData;
|
this.shopQuestionData = shopQuestionData;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
setContainsMilitaryBase(val) {
|
setContainsMilitaryBase(val) {
|
||||||
|
|
|
||||||
|
|
@ -71,7 +71,7 @@ export default {
|
||||||
serviceZipCode: String,
|
serviceZipCode: String,
|
||||||
selectedAppointmentType: String,
|
selectedAppointmentType: String,
|
||||||
cmsWidgetName: String,
|
cmsWidgetName: String,
|
||||||
shopQuestionInitialData: {
|
shopQuestionData: {
|
||||||
type: Object,
|
type: Object,
|
||||||
required: true,
|
required: true,
|
||||||
},
|
},
|
||||||
|
|
@ -102,7 +102,7 @@ export default {
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
loadInitialData() {
|
loadData() {
|
||||||
return baseMixin.methods.dispatchStoreAction(storeActions.GET_PROVIDER_LOCATIONS, {
|
return baseMixin.methods.dispatchStoreAction(storeActions.GET_PROVIDER_LOCATIONS, {
|
||||||
serviceZipCode: this.serviceZipCode,
|
serviceZipCode: this.serviceZipCode,
|
||||||
});
|
});
|
||||||
|
|
@ -165,9 +165,14 @@ export default {
|
||||||
this.displaySeeMoreLocationsLink = true;
|
this.displaySeeMoreLocationsLink = true;
|
||||||
this.selectedValue = "";
|
this.selectedValue = "";
|
||||||
this.$refs.buttonQuestion.resetField();
|
this.$refs.buttonQuestion.resetField();
|
||||||
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
mounted() {
|
||||||
|
console.log(this.shopQuestionData)
|
||||||
|
this.shops = this.shopQuestionData;
|
||||||
|
this.getNextShopsFromList()
|
||||||
|
console.log(this.shops)
|
||||||
|
},
|
||||||
watch: {
|
watch: {
|
||||||
serviceZipCode: {
|
serviceZipCode: {
|
||||||
async handler() {
|
async handler() {
|
||||||
|
|
@ -177,7 +182,7 @@ export default {
|
||||||
selectedAppointmentType: {
|
selectedAppointmentType: {
|
||||||
async handler(newValue, oldValue) {
|
async handler(newValue, oldValue) {
|
||||||
if (oldValue == undefined) {
|
if (oldValue == undefined) {
|
||||||
this.shops = this.shopQuestionInitialData;
|
this.shops = this.shopQuestionData;
|
||||||
this.getNextShopsFromList();
|
this.getNextShopsFromList();
|
||||||
this.displaySeeMoreLocationsLink = true;
|
this.displaySeeMoreLocationsLink = true;
|
||||||
return;
|
return;
|
||||||
|
|
@ -192,7 +197,6 @@ export default {
|
||||||
|
|
||||||
this.resetShopList();
|
this.resetShopList();
|
||||||
},
|
},
|
||||||
immediate: true,
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue