Revert "Merge branch 'develop' into feature/CSR-1382-loose-ends"
This reverts commit8b742bbc44, reversing changes made toc94e3e3740.
This commit is contained in:
parent
8b742bbc44
commit
936bc95957
11 changed files with 56 additions and 84 deletions
|
|
@ -93,7 +93,6 @@ const storeActions = {
|
||||||
SAVE_PIA_ERROR_CODE: "savePiaErrorCode",
|
SAVE_PIA_ERROR_CODE: "savePiaErrorCode",
|
||||||
SAVE_PIA_WORK_ORDER: "savePiaWorkOrder",
|
SAVE_PIA_WORK_ORDER: "savePiaWorkOrder",
|
||||||
SAVE_CCTOKEN: "saveCCToken",
|
SAVE_CCTOKEN: "saveCCToken",
|
||||||
SAVE_PAYPAL_TOKEN: "savePaypalToken",
|
|
||||||
};
|
};
|
||||||
|
|
||||||
export { storeActions };
|
export { storeActions };
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,6 @@ const storeMutations = {
|
||||||
UPDATE_PIA_ERROR_CODE: "updatePiaErrorCode",
|
UPDATE_PIA_ERROR_CODE: "updatePiaErrorCode",
|
||||||
UPDATE_PIA_WORK_ORDER: "updatePiaWorkOrder",
|
UPDATE_PIA_WORK_ORDER: "updatePiaWorkOrder",
|
||||||
UPDATE_CCTOKEN: "updateCCToken",
|
UPDATE_CCTOKEN: "updateCCToken",
|
||||||
UPDATE_PAYPAL_TOKEN: "updatePaypalToken",
|
|
||||||
|
|
||||||
// VEHICLE MUTATIONS
|
// VEHICLE MUTATIONS
|
||||||
UPDATE_YEAR: "updateYear",
|
UPDATE_YEAR: "updateYear",
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="row justify-content-center">
|
<div class="row justify-content-center">
|
||||||
<div class="col-md-6 col-xl-4">
|
<div class="col-md-6">
|
||||||
<vehicleBanner
|
<vehicleBanner
|
||||||
cmsWidgetName="VehicleBannerWidget"
|
cmsWidgetName="VehicleBannerWidget"
|
||||||
:displayGenericVehicleImage="false" />
|
:displayGenericVehicleImage="false" />
|
||||||
|
|
|
||||||
|
|
@ -186,6 +186,7 @@ export default {
|
||||||
lineItems: [],
|
lineItems: [],
|
||||||
availableLineItems: [],
|
availableLineItems: [],
|
||||||
paymentMethodInternalModel: this.getPaymentMethodFromStore(),
|
paymentMethodInternalModel: this.getPaymentMethodFromStore(),
|
||||||
|
displayPiaAlert: this.getPiaAlert(),
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|
@ -244,6 +245,9 @@ export default {
|
||||||
packageReqs && serviceLocationReqs && isInsuranceSet && scheduleReqs && customerReqs
|
packageReqs && serviceLocationReqs && isInsuranceSet && scheduleReqs && customerReqs
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
getPiaAlert() {
|
||||||
|
return store.getters.order.payment.piaErrorCode ? true : false;
|
||||||
|
},
|
||||||
getPaymentMethodFromStore() {
|
getPaymentMethodFromStore() {
|
||||||
const isPia = store.getters.order.payment.isPia;
|
const isPia = store.getters.order.payment.isPia;
|
||||||
|
|
||||||
|
|
@ -262,29 +266,24 @@ export default {
|
||||||
this.$router.navigateWithoutSaving(this.navigationScenarios.CLICKED_BACK, this.$route);
|
this.$router.navigateWithoutSaving(this.navigationScenarios.CLICKED_BACK, this.$route);
|
||||||
},
|
},
|
||||||
async forwardButtonAction() {
|
async forwardButtonAction() {
|
||||||
await this.dispatchStoreAction(
|
|
||||||
storeActions.SAVE_PAYMENT_METHOD_CHOICE,
|
|
||||||
this.paymentMethod,
|
|
||||||
false
|
|
||||||
);
|
|
||||||
|
|
||||||
await this.dispatchStoreAction(storeActions.SAVE_VAPS, this.lineItems.vaps, false);
|
|
||||||
|
|
||||||
await this.dispatchStoreAction(storeActions.SAVE_PROMOS, this.lineItems.promos, false);
|
|
||||||
|
|
||||||
switch (this.paymentMethod) {
|
switch (this.paymentMethod) {
|
||||||
case paymentMethods.CREDIT_CARD:
|
case paymentMethods.CREDIT_CARD:
|
||||||
this.piaSetup(this.paymentMethod);
|
this.piaSetup("cc");
|
||||||
break;
|
break;
|
||||||
case paymentMethods.PAYPAL:
|
case paymentMethods.PAYPAL:
|
||||||
this.piaSetup(this.paymentMethod);
|
this.piaSetup("pp");
|
||||||
break;
|
break;
|
||||||
case paymentMethods.AFTERPAY:
|
case paymentMethods.AFTERPAY:
|
||||||
this.piaSetup(this.paymentMethod);
|
this.piaSetup("ap");
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
this.dispatchStoreAction(storeActions.SAVE_PIA_ERROR_CODE, null, false);
|
this.dispatchStoreAction(storeActions.SAVE_PIA_ERROR_CODE, null, false);
|
||||||
this.dispatchStoreAction(this.storeActions.SAVE_WORK_ORDER_FLAG, true, false);
|
this.dispatchStoreAction(this.storeActions.SAVE_WORK_ORDER_FLAG, true, false);
|
||||||
|
this.dispatchStoreAction(
|
||||||
|
storeActions.SAVE_PAYMENT_METHOD_CHOICE,
|
||||||
|
this.paymentMethod,
|
||||||
|
false
|
||||||
|
);
|
||||||
await submitWorkOrder({ pageNameToLog: "payment-method" });
|
await submitWorkOrder({ pageNameToLog: "payment-method" });
|
||||||
this.$router.navigateWithoutSaving(
|
this.$router.navigateWithoutSaving(
|
||||||
this.navigationScenarios.CLICKED_FORWARD,
|
this.navigationScenarios.CLICKED_FORWARD,
|
||||||
|
|
@ -297,6 +296,11 @@ export default {
|
||||||
|
|
||||||
// since we're leaving the site for pia, clear any save session promises that we will not be able to resolve when we return
|
// since we're leaving the site for pia, clear any save session promises that we will not be able to resolve when we return
|
||||||
await this.dispatchStoreAction(storeActions.RESET_SAVE_SESSION_PROMISE);
|
await this.dispatchStoreAction(storeActions.RESET_SAVE_SESSION_PROMISE);
|
||||||
|
await this.dispatchStoreAction(
|
||||||
|
storeActions.SAVE_PAYMENT_METHOD_CHOICE,
|
||||||
|
payNowType,
|
||||||
|
false
|
||||||
|
);
|
||||||
|
|
||||||
// make sure pia error codes are reset
|
// make sure pia error codes are reset
|
||||||
this.dispatchStoreAction(storeActions.SAVE_PIA_ERROR_CODE, null, false);
|
this.dispatchStoreAction(storeActions.SAVE_PIA_ERROR_CODE, null, false);
|
||||||
|
|
@ -349,9 +353,6 @@ export default {
|
||||||
|
|
||||||
return this.paymentMethodInternalModel;
|
return this.paymentMethodInternalModel;
|
||||||
},
|
},
|
||||||
displayPiaAlert() {
|
|
||||||
return store.getters.order.payment.piaErrorCode ? true : false;
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
customCtaCopy(newValue) {
|
customCtaCopy(newValue) {
|
||||||
|
|
|
||||||
|
|
@ -13,13 +13,18 @@ import store from "@/store";
|
||||||
import baseMixin from "@/mixins/base-mixin.js";
|
import baseMixin from "@/mixins/base-mixin.js";
|
||||||
import loadingModal from "@/fmg-components/loading-modal/loading-modal.vue";
|
import loadingModal from "@/fmg-components/loading-modal/loading-modal.vue";
|
||||||
import { Form } from "vee-validate";
|
import { Form } from "vee-validate";
|
||||||
import { paymentMethods } from "@/constants/payment-method-constants";
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "payment-pia-return",
|
name: "payment-pia-return",
|
||||||
async mounted() {
|
async mounted() {
|
||||||
this.$refs.loadingModal.showModal();
|
this.$refs.loadingModal.showModal();
|
||||||
|
// from paypal
|
||||||
const piaError = getQuerystringParameter(queryStrings.ERROR);
|
const piaError = getQuerystringParameter(queryStrings.ERROR);
|
||||||
|
const token = getQuerystringParameter(queryStrings.TOKEN);
|
||||||
|
const payerId = getQuerystringParameter(queryStrings.PAYERID);
|
||||||
|
|
||||||
|
// from credit card
|
||||||
|
const subscriptionID = getQuerystringParameter(queryStrings.SUBSCRIPTIONID);
|
||||||
|
|
||||||
if (piaError) {
|
if (piaError) {
|
||||||
console.log("Error during payment: " + piaError);
|
console.log("Error during payment: " + piaError);
|
||||||
|
|
@ -30,26 +35,25 @@ export default {
|
||||||
);
|
);
|
||||||
this.$router.navigateWithoutSaving(this.navigationScenarios.PIA_ERROR, this.$route);
|
this.$router.navigateWithoutSaving(this.navigationScenarios.PIA_ERROR, this.$route);
|
||||||
} else {
|
} else {
|
||||||
switch (store.getters.order.payment.piaType) {
|
if (token && payerId) {
|
||||||
case paymentMethods.CREDIT_CARD:
|
await this.processPaypalResponse();
|
||||||
case paymentMethods.AFTERPAY:
|
} else {
|
||||||
await this.processCreditCardResponse();
|
if (subscriptionID) {
|
||||||
break;
|
await this.processCreditCardResponse(subscriptionID);
|
||||||
case paymentMethods.PAYPAL:
|
} else {
|
||||||
await this.processPaypalResponse();
|
console.log(
|
||||||
break;
|
"Error during payment: " + token + " : " + payerId + " : " + subscriptionID
|
||||||
default:
|
);
|
||||||
var msg = "Unknown Pia type: " + store.getters.order.payment.piaType;
|
|
||||||
console.log(msg);
|
|
||||||
baseMixin.methods.dispatchStoreAction(
|
baseMixin.methods.dispatchStoreAction(
|
||||||
storeActions.SAVE_PIA_ERROR_CODE,
|
storeActions.SAVE_PIA_ERROR_CODE,
|
||||||
msg,
|
piaError,
|
||||||
false
|
false
|
||||||
);
|
);
|
||||||
this.$router.navigateWithoutSaving(
|
this.$router.navigateWithoutSaving(
|
||||||
this.navigationScenarios.PIA_ERROR,
|
this.navigationScenarios.PIA_ERROR,
|
||||||
this.$route
|
this.$route
|
||||||
);
|
);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
@ -58,16 +62,12 @@ export default {
|
||||||
return true;
|
return true;
|
||||||
},
|
},
|
||||||
async processPaypalResponse() {
|
async processPaypalResponse() {
|
||||||
const token = getQuerystringParameter(queryStrings.TOKEN);
|
|
||||||
const payerId = getQuerystringParameter(queryStrings.PAYERID);
|
|
||||||
baseMixin.methods.dispatchStoreAction(storeActions.SAVE_PIA_ERROR_CODE, null, false);
|
baseMixin.methods.dispatchStoreAction(storeActions.SAVE_PIA_ERROR_CODE, null, false);
|
||||||
baseMixin.methods.dispatchStoreAction(storeActions.SAVE_WORK_ORDER_FLAG, true, false);
|
baseMixin.methods.dispatchStoreAction(storeActions.SAVE_WORK_ORDER_FLAG, true, false);
|
||||||
baseMixin.methods.dispatchStoreAction(storeActions.SAVE_PAYPAL_TOKEN, token, false);
|
|
||||||
|
|
||||||
await this.saveAndSubmitWorkOrder();
|
await this.saveAndSubmitWorkOrder();
|
||||||
},
|
},
|
||||||
async processCreditCardResponse() {
|
async processCreditCardResponse(subscriptionID) {
|
||||||
const subscriptionID = getQuerystringParameter(queryStrings.SUBSCRIPTIONID);
|
|
||||||
baseMixin.methods.dispatchStoreAction(storeActions.SAVE_PIA_ERROR_CODE, null, false);
|
baseMixin.methods.dispatchStoreAction(storeActions.SAVE_PIA_ERROR_CODE, null, false);
|
||||||
baseMixin.methods.dispatchStoreAction(storeActions.SAVE_WORK_ORDER_FLAG, true, false);
|
baseMixin.methods.dispatchStoreAction(storeActions.SAVE_WORK_ORDER_FLAG, true, false);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -168,7 +168,6 @@ import { externalUrls } from "@/router/router-constants/externalUrl-values";
|
||||||
import { fetchCmsContentForPage } from "@/helpers/cms-content-helper";
|
import { fetchCmsContentForPage } from "@/helpers/cms-content-helper";
|
||||||
import { settleAllPromises } from "@/helpers/layout-helper";
|
import { settleAllPromises } from "@/helpers/layout-helper";
|
||||||
import { applicationConfig } from "@/constants/application-config";
|
import { applicationConfig } from "@/constants/application-config";
|
||||||
import { paymentMethods } from "@/constants/payment-method-constants";
|
|
||||||
import baseMixin from "@/mixins/base-mixin.js";
|
import baseMixin from "@/mixins/base-mixin.js";
|
||||||
|
|
||||||
// Validation
|
// Validation
|
||||||
|
|
@ -287,16 +286,7 @@ export default {
|
||||||
: store.getters.order.serviceLocation.provider.address.zipCode;
|
: store.getters.order.serviceLocation.provider.address.zipCode;
|
||||||
},
|
},
|
||||||
getPaymentType() {
|
getPaymentType() {
|
||||||
switch (store.getters.order.payment.piaType) {
|
return store.getters.order.payment.piaType;
|
||||||
case paymentMethods.AFTERPAY:
|
|
||||||
return "ap";
|
|
||||||
case paymentMethods.CREDIT_CARD:
|
|
||||||
return "cc";
|
|
||||||
case paymentMethods.PAYPAL:
|
|
||||||
return "pp";
|
|
||||||
default:
|
|
||||||
return store.getters.payment.piaType;
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
getHeaderLine1() {
|
getHeaderLine1() {
|
||||||
if (!this.isPaypal()) {
|
if (!this.isPaypal()) {
|
||||||
|
|
@ -326,11 +316,11 @@ export default {
|
||||||
return itemsForPia;
|
return itemsForPia;
|
||||||
},
|
},
|
||||||
getAmountDue() {
|
getAmountDue() {
|
||||||
return 2;
|
return 350.0;
|
||||||
//return baseMixin.methods.getAmountDue(store.getters.order.lineItems);
|
//return baseMixin.methods.getAmountDue(store.getters.order.lineItems);
|
||||||
},
|
},
|
||||||
getDisplayAmountDue() {
|
getDisplayAmountDue() {
|
||||||
return "$2.00";
|
return "$350.00";
|
||||||
//return baseMixin.methods.getDisplayAmountDue(store.getters.order.lineItems);
|
//return baseMixin.methods.getDisplayAmountDue(store.getters.order.lineItems);
|
||||||
},
|
},
|
||||||
isPaypal() {
|
isPaypal() {
|
||||||
|
|
|
||||||
|
|
@ -265,7 +265,7 @@ export default {
|
||||||
}
|
}
|
||||||
|
|
||||||
this.dispatchStoreAction(this.storeActions.SAVE_VAPS, this.selectedVaps, false);
|
this.dispatchStoreAction(this.storeActions.SAVE_VAPS, this.selectedVaps, false);
|
||||||
this.dispatchStoreAction(this.storeActions.SAVE_PROMOS, this.allActivePromos, false);
|
this.dispatchStoreAction(this.storeActions.SAVE_PROMOS, this.newValidatedPromos, false);
|
||||||
|
|
||||||
const payment = this.$store.getters.payment;
|
const payment = this.$store.getters.payment;
|
||||||
if (payment.isInsurance) {
|
if (payment.isInsurance) {
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="row justify-content-center">
|
<div class="row justify-content-center">
|
||||||
<div class="col-md-6 col-xl-4">
|
<div class="col-md-6 col-xl-4">
|
||||||
<funnelSubHeader cmsWidgetName="FunnelSubHeaderWidget" class="mt-4" />
|
<funnelSubHeader cmsWidgetName="FunnelSubHeaderWidget" class="mt-5" />
|
||||||
<template v-if="ChangeShopLink.length">
|
<template v-if="ChangeShopLink.length">
|
||||||
<textBlock
|
<textBlock
|
||||||
cmsWidgetName="ChangeShopLink"
|
cmsWidgetName="ChangeShopLink"
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="row justify-content-center">
|
<div class="row justify-content-center">
|
||||||
<div class="col-md-6 col-xl-4">
|
<div class="col-md-6 col-lg-4">
|
||||||
<vehicleBanner
|
<vehicleBanner
|
||||||
ref="vehicleBanner"
|
ref="vehicleBanner"
|
||||||
cmsWidgetName="VehicleBannerWidget"
|
cmsWidgetName="VehicleBannerWidget"
|
||||||
|
|
|
||||||
|
|
@ -124,17 +124,16 @@ export default {
|
||||||
},
|
},
|
||||||
getAmountDue(lineItems) {
|
getAmountDue(lineItems) {
|
||||||
// TODO: verify tax is included in lineitems
|
// TODO: verify tax is included in lineitems
|
||||||
|
// Price everything in lineitems except the server data string
|
||||||
var amountDue = 0;
|
var amountDue = 0;
|
||||||
if (lineItems.glassParts) {
|
const itemsClone = { ...lineItems };
|
||||||
amountDue = this.getTotalPriceOfAllLineItemsAndChildParts(lineItems.glassParts);
|
delete itemsClone.serverData;
|
||||||
}
|
for (var propertyName in itemsClone) {
|
||||||
if (lineItems.supportingItems) {
|
if (itemsClone[propertyName]) {
|
||||||
amountDue += this.getTotalPriceOfAllLineItemsAndChildParts(
|
amountDue += this.getTotalPriceOfAllLineItemsAndChildParts(
|
||||||
lineItems.supportingItems
|
itemsClone[propertyName]
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
if (lineItems.supportingItems.vaps) {
|
|
||||||
amountDue += this.getTotalPriceOfAllLineItemsAndChildParts(lineItems.vaps);
|
|
||||||
}
|
}
|
||||||
return amountDue;
|
return amountDue;
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -99,7 +99,6 @@ const getDefaultState = () => {
|
||||||
piaType: null,
|
piaType: null,
|
||||||
piaErrorCode: null,
|
piaErrorCode: null,
|
||||||
inactivePromos: null,
|
inactivePromos: null,
|
||||||
paypalToken: null,
|
|
||||||
ccToken: {
|
ccToken: {
|
||||||
subscriptionId: null,
|
subscriptionId: null,
|
||||||
expMonth: null,
|
expMonth: null,
|
||||||
|
|
@ -271,9 +270,6 @@ export const mutations = {
|
||||||
state.order.payment.ccToken.transactionId = ccToken.transactionId;
|
state.order.payment.ccToken.transactionId = ccToken.transactionId;
|
||||||
state.order.payment.ccToken.transReferenceNumber = ccToken.transReferenceNumber;
|
state.order.payment.ccToken.transReferenceNumber = ccToken.transReferenceNumber;
|
||||||
},
|
},
|
||||||
updatePaypalToken(state, ppToken) {
|
|
||||||
state.order.payment.paypalToken = ppToken;
|
|
||||||
},
|
|
||||||
updateInsuranceVerifiedStatus(state, isVerified) {
|
updateInsuranceVerifiedStatus(state, isVerified) {
|
||||||
state.order.payment.insuranceCoverage.isVerified = isVerified;
|
state.order.payment.insuranceCoverage.isVerified = isVerified;
|
||||||
},
|
},
|
||||||
|
|
@ -499,12 +495,10 @@ export const mutations = {
|
||||||
state.order.lineItems.glassParts = sessionInformation.order.lineItems.glassParts;
|
state.order.lineItems.glassParts = sessionInformation.order.lineItems.glassParts;
|
||||||
state.order.lineItems.supportingItems = sessionInformation.order.lineItems.supportingItems;
|
state.order.lineItems.supportingItems = sessionInformation.order.lineItems.supportingItems;
|
||||||
state.order.lineItems.vaps = sessionInformation.order.lineItems.vaps;
|
state.order.lineItems.vaps = sessionInformation.order.lineItems.vaps;
|
||||||
state.order.lineItems.promos = sessionInformation.order.lineItems.promos;
|
|
||||||
state.order.lineItems.serverData = sessionInformation.order.lineItems.serverData;
|
state.order.lineItems.serverData = sessionInformation.order.lineItems.serverData;
|
||||||
|
|
||||||
state.order.payment.parentAccountNumber =
|
state.order.payment.parentAccountNumber =
|
||||||
sessionInformation.order.payment.parentAccountNumber;
|
sessionInformation.order.payment.parentAccountNumber;
|
||||||
state.order.payment.inactivePromos = sessionInformation.order.payment.inactivePromos;
|
|
||||||
|
|
||||||
state.order.serviceLocation.address =
|
state.order.serviceLocation.address =
|
||||||
sessionInformation.order.serviceLocation.streetAddress;
|
sessionInformation.order.serviceLocation.streetAddress;
|
||||||
|
|
@ -1650,11 +1644,6 @@ export const actions = {
|
||||||
isInsurance: order.payment.isInsurance,
|
isInsurance: order.payment.isInsurance,
|
||||||
parentAccountNumber: order.payment.parentAccountNumber,
|
parentAccountNumber: order.payment.parentAccountNumber,
|
||||||
inactivePromos: order.payment.inactivePromos,
|
inactivePromos: order.payment.inactivePromos,
|
||||||
isCreditCard:
|
|
||||||
order.payment.piaType == paymentMethods.CREDIT_CARD ? true : false,
|
|
||||||
isPaypal: order.payment.piaType == paymentMethods.PAYPAL ? true : false,
|
|
||||||
isAfterPay: order.payment.piaType == paymentMethods.AFTERPAY ? true : false,
|
|
||||||
paypalToken: order.payment.paypalToken,
|
|
||||||
ccToken: {
|
ccToken: {
|
||||||
subscriptionId: order.payment.ccToken.subscriptionId,
|
subscriptionId: order.payment.ccToken.subscriptionId,
|
||||||
expMonth: order.payment.ccToken.expMonth,
|
expMonth: order.payment.ccToken.expMonth,
|
||||||
|
|
@ -1788,9 +1777,6 @@ export const actions = {
|
||||||
saveCCToken(context, ccToken) {
|
saveCCToken(context, ccToken) {
|
||||||
context.commit(storeMutations.UPDATE_CCTOKEN, ccToken);
|
context.commit(storeMutations.UPDATE_CCTOKEN, ccToken);
|
||||||
},
|
},
|
||||||
savePaypalToken(context, ppToken) {
|
|
||||||
context.commit(storeMutations.UPDATE_PAYPAL_TOKEN, ppToken);
|
|
||||||
},
|
|
||||||
|
|
||||||
// Business domain actions
|
// Business domain actions
|
||||||
|
|
||||||
|
|
@ -2252,7 +2238,6 @@ export const actions = {
|
||||||
addGuidToLineItemsIfNotAlreadyThere(addableVaps);
|
addGuidToLineItemsIfNotAlreadyThere(addableVaps);
|
||||||
const requestObject = {
|
const requestObject = {
|
||||||
promoCode: promoCode,
|
promoCode: promoCode,
|
||||||
addableVaps: addableVaps,
|
|
||||||
order: {
|
order: {
|
||||||
appointmentType: order.serviceLocation.appointmentType,
|
appointmentType: order.serviceLocation.appointmentType,
|
||||||
carId: order.vehicle.carId,
|
carId: order.vehicle.carId,
|
||||||
|
|
@ -2261,6 +2246,7 @@ export const actions = {
|
||||||
isRepair: order.damage.isRepair,
|
isRepair: order.damage.isRepair,
|
||||||
glassToReplace: renameGlassToReplaceAttributes(order.damage.glassToReplace),
|
glassToReplace: renameGlassToReplaceAttributes(order.damage.glassToReplace),
|
||||||
lineItemsOnOrder: getArrayOfAllLineItems(order.lineItems),
|
lineItemsOnOrder: getArrayOfAllLineItems(order.lineItems),
|
||||||
|
addableVaps: addableVaps,
|
||||||
parentAccountNumber: order.payment.parentAccountNumber,
|
parentAccountNumber: order.payment.parentAccountNumber,
|
||||||
referralSequenceNumber: order.referralSequenceNumber,
|
referralSequenceNumber: order.referralSequenceNumber,
|
||||||
serviceState: order.serviceLocation.state,
|
serviceState: order.serviceLocation.state,
|
||||||
|
|
@ -2281,12 +2267,10 @@ export const actions = {
|
||||||
pageNameToLog: pageNameToLog,
|
pageNameToLog: pageNameToLog,
|
||||||
});
|
});
|
||||||
|
|
||||||
if (validateResponse?.data?.serverData) {
|
context.commit(
|
||||||
context.commit(
|
storeMutations.UPDATE_LINE_ITEMS_SERVER_DATA,
|
||||||
storeMutations.UPDATE_LINE_ITEMS_SERVER_DATA,
|
validateResponse.data.lineItemsServerData
|
||||||
validateResponse.data.serverData
|
);
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
return validateResponse;
|
return validateResponse;
|
||||||
},
|
},
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue