coverage-statement refactoring WIP
This commit is contained in:
parent
b986857615
commit
e8f9adfaaa
1 changed files with 23 additions and 6 deletions
|
|
@ -59,6 +59,8 @@ import { getDamageString } from '@/helpers/damage-helper.js';
|
|||
import { useMainStore } from "@/store";
|
||||
import vehicleQuestionsMixin from "@/mixins/vehicle-questions-mixin";
|
||||
|
||||
const store = useMainStore();
|
||||
|
||||
export default {
|
||||
name: 'coverage-statement',
|
||||
mixins: [baseFormMixin, vehicleQuestionsMixin],
|
||||
|
|
@ -71,6 +73,11 @@ export default {
|
|||
recalModal,
|
||||
steeringText
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
selectedVehicle: useMainStore().order.vehicle
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
setupModalLinks(this);
|
||||
},
|
||||
|
|
@ -93,21 +100,31 @@ export default {
|
|||
}
|
||||
},
|
||||
continueWithSchedulingBodyText() {
|
||||
return this.getCmsContent("continueWithSchedulingCopy", "BodyText");
|
||||
return this.getCmsContent("continueWithSchedulingCopy", "BodyText");
|
||||
},
|
||||
unverifiedADASNextStepsBodyText() {
|
||||
return this.getCmsContent("UnverifiedADASNextStepsWidget", "BodyText").replaceAll("{custom:damage}", this.damageText);
|
||||
return this.getCmsContent("UnverifiedADASNextStepsWidget", "BodyText").replaceAll("{custom:damage}", this.damageText);
|
||||
},
|
||||
unverifiedNonADASNextStepsBodyText() {
|
||||
return this.getCmsContent("UnverifiedNonADASNextStepsWidget", "BodyText").replaceAll("{custom:damage}", this.damageText);
|
||||
return this.getCmsContent("UnverifiedNonADASNextStepsWidget", "BodyText").replaceAll("{custom:damage}", this.damageText);
|
||||
},
|
||||
unverifiedNonADASRepairBodyText() {
|
||||
return this.getCmsContent("UnverifiedNonADASRepairWidget", "BodyText");
|
||||
return this.getCmsContent("UnverifiedNonADASRepairWidget", "BodyText");
|
||||
},
|
||||
damageText() {
|
||||
var damageString = getDamageString();
|
||||
return damageString == "match" ? "" : damageString;
|
||||
var damageString = getDamageString();
|
||||
return damageString == "match" ? "" : damageString;
|
||||
},
|
||||
coverageVerified() {
|
||||
const isCoverageVerified = store.order.payment.insuranceCoverage.isVerified;
|
||||
return isCoverageVerified;
|
||||
},
|
||||
verifiedNoComp() {
|
||||
const policyData = store.applicationUser.pageData.policyVehicles;
|
||||
if (!policyData.coverages || policyData.noCoverage === true) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
},
|
||||
async beforeRouteEnter(to, from, next) {
|
||||
// Call APIs
|
||||
|
|
|
|||
Loading…
Reference in a new issue