Merge branch 'develop' into feature/CSR-92
This commit is contained in:
commit
3935e8acc6
5 changed files with 688 additions and 647 deletions
1257
package-lock.json
generated
1257
package-lock.json
generated
File diff suppressed because it is too large
Load diff
|
|
@ -57,8 +57,13 @@ export default {
|
||||||
const fieldOptions = {
|
const fieldOptions = {
|
||||||
type: "text",
|
type: "text",
|
||||||
value: props.modelValue,
|
value: props.modelValue,
|
||||||
|
potentialInitialValue: props.modelValue,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
if (props.modelValue && props.modelValue.length > 0) {
|
||||||
|
fieldOptions['initialValue'] = fieldOptions.potentialInitialValue;
|
||||||
|
}
|
||||||
|
|
||||||
const {
|
const {
|
||||||
errorMessage,
|
errorMessage,
|
||||||
handleBlur,
|
handleBlur,
|
||||||
|
|
@ -98,10 +103,10 @@ export default {
|
||||||
words.forEach(function (word) {
|
words.forEach(function (word) {
|
||||||
const position = 1;
|
const position = 1;
|
||||||
word = [word.toString().slice(0, position), noBreakChar, word.toString().slice(position)].join('');
|
word = [word.toString().slice(0, position), noBreakChar, word.toString().slice(position)].join('');
|
||||||
questionText += `${word} `;
|
questionText += `${word} `;
|
||||||
});
|
});
|
||||||
|
|
||||||
questionText = questionText.trimEnd();
|
questionText = questionText.trimEnd();
|
||||||
} else {
|
} else {
|
||||||
questionText = this.questionText.toString();
|
questionText = this.questionText.toString();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -62,16 +62,9 @@
|
||||||
:manualHeadline="MatchedDifferentVehicleAlertHeader"
|
:manualHeadline="MatchedDifferentVehicleAlertHeader"
|
||||||
:manualCopy="MatchedDifferentVehicleAlertBody"
|
:manualCopy="MatchedDifferentVehicleAlertBody"
|
||||||
v-model="customAlertData"
|
v-model="customAlertData"
|
||||||
v-if="matchedDifferentVehicle"
|
v-if="isCarIdDifferent"
|
||||||
alertClass="alert-danger"
|
alertClass="alert-danger"
|
||||||
/>
|
/>
|
||||||
<alert
|
|
||||||
class="my-3"
|
|
||||||
v-model="customAlertData"
|
|
||||||
v-if="noMatchAlert"
|
|
||||||
alertClass="alert-warning"
|
|
||||||
cmsWidgetName="NoMatchAlertWidget"
|
|
||||||
/>
|
|
||||||
<alert
|
<alert
|
||||||
class="my-3"
|
class="my-3"
|
||||||
:manualHeadline="NoServiceZipHeader"
|
:manualHeadline="NoServiceZipHeader"
|
||||||
|
|
@ -80,13 +73,6 @@
|
||||||
v-if="noServiceZip"
|
v-if="noServiceZip"
|
||||||
alertClass="alert-warning"
|
alertClass="alert-warning"
|
||||||
/>
|
/>
|
||||||
<alert
|
|
||||||
class="my-3"
|
|
||||||
v-model="customAlertData"
|
|
||||||
v-if="foundWindshieldAlert"
|
|
||||||
alertClass="alert-warning"
|
|
||||||
cmsWidgetName="FoundWindshieldAlert"
|
|
||||||
/>
|
|
||||||
<alert
|
<alert
|
||||||
class="my-3"
|
class="my-3"
|
||||||
v-model="customAlertData"
|
v-model="customAlertData"
|
||||||
|
|
@ -98,7 +84,7 @@
|
||||||
class="my-3"
|
class="my-3"
|
||||||
v-model="customAlertData"
|
v-model="customAlertData"
|
||||||
v-if="perfectMatchNewVinAlert"
|
v-if="perfectMatchNewVinAlert"
|
||||||
alertClass="alert-warning"
|
alertClass="alert-success"
|
||||||
cmsWidgetName="PerfectMatchNewVinAlert"
|
cmsWidgetName="PerfectMatchNewVinAlert"
|
||||||
/>
|
/>
|
||||||
<funnelFooter
|
<funnelFooter
|
||||||
|
|
@ -175,44 +161,39 @@ export default {
|
||||||
vm.setCmsContent(resultMap.cmsContent);
|
vm.setCmsContent(resultMap.cmsContent);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
props: {
|
|
||||||
validationRules: String,
|
|
||||||
},
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
matchedDifferentVehicle: false,
|
isCarIdDifferent: false,
|
||||||
noMatchAlert: false,
|
|
||||||
noServiceZip: false,
|
noServiceZip: false,
|
||||||
vinFound: false,
|
|
||||||
vinFoundReadOnly: false,
|
|
||||||
foundWindshieldAlert: false,
|
|
||||||
vinNotFound: false,
|
vinNotFound: false,
|
||||||
perfectMatchNewVinAlert: false,
|
|
||||||
vin: this.getVinFromStore(),
|
vin: this.getVinFromStore(),
|
||||||
zip: this.getZipFromStore(),
|
zip: this.getZipFromStore(),
|
||||||
email: this.getEmailFromStore(),
|
email: this.getEmailFromStore(),
|
||||||
customAlertData: {},
|
customAlertData: {},
|
||||||
isCarIdDifferent: false,
|
|
||||||
previouslyEnteredCarId: '',
|
previouslyEnteredCarId: '',
|
||||||
invalidZip: '',
|
invalidZip: '',
|
||||||
|
vinPopulatedOnPageLoad: this.getVinFromStore()?.length > 0,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
|
perfectMatchNewVinAlert() {
|
||||||
|
return this.vinPopulatedOnPageLoad && this.vin === this.getVinFromStore();
|
||||||
|
},
|
||||||
MatchedDifferentVehicleAlertHeader(){
|
MatchedDifferentVehicleAlertHeader(){
|
||||||
let text = this.getCmsContent("MatchedDifferentVehicle",
|
const text = this.getCmsContent("MatchedDifferentVehicle",
|
||||||
"HeadlineText").replaceAll("{custom:damage}", getDamageString());
|
"HeadlineText").replaceAll("{custom:damage}", getDamageString());
|
||||||
|
|
||||||
return text;
|
return text;
|
||||||
},
|
},
|
||||||
MatchedDifferentVehicleAlertBody(){
|
MatchedDifferentVehicleAlertBody(){
|
||||||
let text = this.getCmsContent("MatchedDifferentVehicle",
|
const text = this.getCmsContent("MatchedDifferentVehicle",
|
||||||
"BodyText").replaceAll("{custom:damage}", getDamageString()).replaceAll("{custom:vinlookupYear}", this.customAlertData?.vehicleInfo?.year).replaceAll("{custom:vinlookupMake}", this.customAlertData?.vehicleInfo?.make).replaceAll("{custom:vinlookupModel}",
|
"BodyText").replaceAll("{custom:damage}", getDamageString()).replaceAll("{custom:vinlookupYear}", this.customAlertData?.vehicleInfo?.year).replaceAll("{custom:vinlookupMake}", this.customAlertData?.vehicleInfo?.make).replaceAll("{custom:vinlookupModel}",
|
||||||
this.customAlertData?.vehicleInfo?.model);
|
this.customAlertData?.vehicleInfo?.model);
|
||||||
|
|
||||||
return text;
|
return text;
|
||||||
},
|
},
|
||||||
NoServiceZipHeader(){
|
NoServiceZipHeader(){
|
||||||
let text = this.getCmsContent("NoServiceZipWidget", "HeadlineText").replaceAll("{custom:serviceZip}", this.invalidZip);
|
const text = this.getCmsContent("NoServiceZipWidget", "HeadlineText").replaceAll("{custom:serviceZip}", this.invalidZip);
|
||||||
|
|
||||||
return text;
|
return text;
|
||||||
},
|
},
|
||||||
|
|
@ -288,7 +269,7 @@ export default {
|
||||||
this.isVinValid = true;
|
this.isVinValid = true;
|
||||||
this.isSelectedGlassAvailableForVehicle = await isGlassAvailableForCarId(vehicleLookup.data.carId);
|
this.isSelectedGlassAvailableForVehicle = await isGlassAvailableForCarId(vehicleLookup.data.carId);
|
||||||
this.$refs.funnelFooter.removeLoader();
|
this.$refs.funnelFooter.removeLoader();
|
||||||
this.matchedDifferentVehicle = true;
|
this.isCarIdDifferent = true;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
this.updateStore(vehicleLookup.data);
|
this.updateStore(vehicleLookup.data);
|
||||||
|
|
|
||||||
|
|
@ -102,19 +102,11 @@ const routingTable = [
|
||||||
maps: [
|
maps: [
|
||||||
{
|
{
|
||||||
scenario: navigationScenarios.CLICKED_BACK,
|
scenario: navigationScenarios.CLICKED_BACK,
|
||||||
destinationFmgPageValue: fmgPageValues.REVEAL,
|
destinationFmgPageValue: fmgPageValues.ESTIMATE,
|
||||||
},
|
|
||||||
{
|
|
||||||
scenario: navigationScenarios.CLICKED_BACK_WITH_VIN,
|
|
||||||
destinationFmgPageValue: fmgPageValues.VEHICLE_DAMAGE,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
scenario: navigationScenarios.VIN_LOOKUP,
|
|
||||||
destinationFmgPageValue: fmgPageValues.PART_QUESTIONS,
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
scenario: navigationScenarios.CLICKED_FORWARD,
|
scenario: navigationScenarios.CLICKED_FORWARD,
|
||||||
destinationFmgPageValue: fmgPageValues.ESTIMATE,
|
destinationFmgPageValue: fmgPageValues.VEHICLE_DAMAGE,
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
|
|
@ -145,7 +137,7 @@ const routingTable = [
|
||||||
{
|
{
|
||||||
scenario: navigationScenarios.CLICKED_FORWARD,
|
scenario: navigationScenarios.CLICKED_FORWARD,
|
||||||
destinationFmgPageValue: fmgPageValues.VEHICLE_DAMAGE,
|
destinationFmgPageValue: fmgPageValues.VEHICLE_DAMAGE,
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
{fmgPageValue: fmgPageValues.ESTIMATE,
|
{fmgPageValue: fmgPageValues.ESTIMATE,
|
||||||
|
|
|
||||||
|
|
@ -144,17 +144,17 @@ export const mutations = {
|
||||||
updateRegistrationAddress(state, registrationAddress){
|
updateRegistrationAddress(state, registrationAddress){
|
||||||
state.order.vehicle.registration.address = registrationAddress;
|
state.order.vehicle.registration.address = registrationAddress;
|
||||||
},
|
},
|
||||||
updateServiceLocationZipCode(state, serviceLocationZipCode){
|
updateServiceLocationZip(state, serviceLocationZip){
|
||||||
state.order.serviceLocation.zipCode = serviceLocationZipCode;
|
state.order.vehicle.registration.zip = serviceLocationZip;
|
||||||
},
|
},
|
||||||
updateRegistrationCity(state, serviceCity){
|
updateRegistrationCity(state, serviceCity){
|
||||||
state.order.serviceLocation.city = serviceCity;
|
state.order.vehicle.registration.city = serviceCity;
|
||||||
},
|
},
|
||||||
updateRegistrationFirstName(state, firstName){
|
updateRegistrationFirstName(state, firstName){
|
||||||
state.order.serviceLocation.firstName = firstName;
|
state.order.vehicle.registration.firstName = firstName;
|
||||||
},
|
},
|
||||||
updateRegistrationLastName(state, lastName){
|
updateRegistrationLastName(state, lastName){
|
||||||
state.order.serviceLocation.lastName = lastName;
|
state.order.vehicle.registration.lastName = lastName;
|
||||||
},
|
},
|
||||||
updateCustomerEmailAddress(state, customerEmailAddress){
|
updateCustomerEmailAddress(state, customerEmailAddress){
|
||||||
state.order.customer.emailAddress = customerEmailAddress;
|
state.order.customer.emailAddress = customerEmailAddress;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue