Merge pull request #1434 from Safelite/feature/CSR-1384-modals-for-add-vaps
CSR-1384: fixes to keep dev working
This commit is contained in:
commit
decfc9d949
2 changed files with 7 additions and 6 deletions
|
|
@ -44,13 +44,13 @@ export default {
|
||||||
showAddRainDefense() {
|
showAddRainDefense() {
|
||||||
// if not found in the cart
|
// if not found in the cart
|
||||||
return !this.cartItems.some((vap) => {
|
return !this.cartItems.some((vap) => {
|
||||||
return vap.partType === "RAIN DEFENSE";
|
return vap?.partType === "RAIN DEFENSE";
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
showAddWipers() {
|
showAddWipers() {
|
||||||
// if not found in the cart
|
// if not found in the cart
|
||||||
return !this.cartItems.some((vap) => {
|
return !this.cartItems.some((vap) => {
|
||||||
return vap.partType.includes(" WIPER");
|
return vap?.partType?.includes(" WIPER");
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
rainDefensePrice() {
|
rainDefensePrice() {
|
||||||
|
|
|
||||||
|
|
@ -159,7 +159,10 @@ export default {
|
||||||
|
|
||||||
const lineItems = store.getters.order.lineItems;
|
const lineItems = store.getters.order.lineItems;
|
||||||
|
|
||||||
const combinedLineItems = [...glassParts, ...lineItems.supportingItems, ...lineItems.vaps];
|
const combinedLineItems = [];
|
||||||
|
combinedLineItems.push(lineItems.glassParts ?? []);
|
||||||
|
combinedLineItems.push(lineItems.supportingItems ?? []);
|
||||||
|
combinedLineItems.push(lineItems.vaps ?? []);
|
||||||
|
|
||||||
const taxedLineItems = await baseMixin.methods.dispatchStoreActionWithLogging(
|
const taxedLineItems = await baseMixin.methods.dispatchStoreActionWithLogging(
|
||||||
storeActions.TAX_ORDER_ITEMS_AND_SAVE_SERVER_DATA,
|
storeActions.TAX_ORDER_ITEMS_AND_SAVE_SERVER_DATA,
|
||||||
|
|
@ -175,11 +178,9 @@ export default {
|
||||||
false
|
false
|
||||||
);
|
);
|
||||||
|
|
||||||
const cartItems = [...glassParts, ...lineItems.supportingItems, ...lineItems.vaps]; // TOBEREMOVED BY AJC IN CSR-1384
|
|
||||||
|
|
||||||
// Call the "next" function to complete the transition to this page.
|
// Call the "next" function to complete the transition to this page.
|
||||||
next((vm) => {
|
next((vm) => {
|
||||||
vm.cartItems = cartItems; // TOBEREMOVED BY AJC IN CSR-1384
|
vm.cartItems = combinedLineItems; // TOBEREMOVED BY AJC IN CSR-1384
|
||||||
|
|
||||||
vm.setCmsContent(resultMap.cmsContent);
|
vm.setCmsContent(resultMap.cmsContent);
|
||||||
vm.availableLineItems = pricedAvailableLineItems;
|
vm.availableLineItems = pricedAvailableLineItems;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue