CSR-747 Navigation for repairs
This commit is contained in:
parent
aa6aad7c07
commit
506b520b30
4 changed files with 17 additions and 3 deletions
|
|
@ -328,8 +328,15 @@ export default {
|
||||||
},
|
},
|
||||||
|
|
||||||
navigateForward() {
|
navigateForward() {
|
||||||
|
const payment = store.getters.payment;
|
||||||
|
if (payment.isInsurance && payment.insuranceCoverage.coverageStatus === "VERIFIED") {
|
||||||
|
this.$router.navigateWithSaving(
|
||||||
|
this.navigationScenarios.CLICKED_FORWARD_WITH_VERIFIED_INSURANCE,
|
||||||
|
this.$route
|
||||||
|
);
|
||||||
|
}
|
||||||
// If vin already exists, navigate directly to vin-lookup
|
// If vin already exists, navigate directly to vin-lookup
|
||||||
if (store.getters.vehicle.vin) {
|
else if (store.getters.vehicle.vin) {
|
||||||
this.$router.navigateWithSaving(
|
this.$router.navigateWithSaving(
|
||||||
this.navigationScenarios.CLICKED_FORWARD_WITH_VIN,
|
this.navigationScenarios.CLICKED_FORWARD_WITH_VIN,
|
||||||
this.$route
|
this.$route
|
||||||
|
|
|
||||||
|
|
@ -458,8 +458,10 @@ export default {
|
||||||
self.$store.commit(storeMutations.UPDATE_GLASS_PARTS, collectedGlassParts);
|
self.$store.commit(storeMutations.UPDATE_GLASS_PARTS, collectedGlassParts);
|
||||||
|
|
||||||
const payment = self.$store.getters.payment;
|
const payment = self.$store.getters.payment;
|
||||||
// TODO KO If coverageStatus is null, they haven't gone to heritage yet... I think
|
// TODO KO If coverageStatus is null, they haven't been to heritage yet...
|
||||||
shouldGoToHeritageQuote || (payment.isInsurance && payment.insuranceCoverage.coverageStatus)
|
// TODO KO what happens if you go to CCPolicyInfo (insurance), go back to vin-lookup, and go forward.
|
||||||
|
// Does it skip quote?
|
||||||
|
shouldGoToHeritageQuote || (payment.isInsurance && payment.insuranceCoverage.isVerified)
|
||||||
? navigateToHeritageFunnel({loadingModal: self.$refs.loadingModal})
|
? navigateToHeritageFunnel({loadingModal: self.$refs.loadingModal})
|
||||||
: self.$router.navigateWithSaving(
|
: self.$router.navigateWithSaving(
|
||||||
self.navigationScenarios.HAS_NO_MORE_QUESTIONS,
|
self.navigationScenarios.HAS_NO_MORE_QUESTIONS,
|
||||||
|
|
|
||||||
|
|
@ -12,6 +12,7 @@ const navigationScenarios = {
|
||||||
// Vin pages
|
// Vin pages
|
||||||
CLICKED_BACK_WITH_VIN: "CLICKED_BACK_WITH_VIN",
|
CLICKED_BACK_WITH_VIN: "CLICKED_BACK_WITH_VIN",
|
||||||
CLICKED_FORWARD_WITH_VIN: "CLICKED_FORWARD_WITH_VIN",
|
CLICKED_FORWARD_WITH_VIN: "CLICKED_FORWARD_WITH_VIN",
|
||||||
|
CLICKED_FORWARD_WITH_VERIFIED_INSURANCE: "CLICKED_FORWARD_WITH_VERIFIED_INSURANCE",
|
||||||
CLICKED_FORWARD_WITHOUT_VIN: "CLICKED_FORWARD_WITHOUT_VIN",
|
CLICKED_FORWARD_WITHOUT_VIN: "CLICKED_FORWARD_WITHOUT_VIN",
|
||||||
CONTINUING_WITH_MULTIPLE_VEHICLES: "CONTINUING_WITH_MULTIPLE_VEHICLES",
|
CONTINUING_WITH_MULTIPLE_VEHICLES: "CONTINUING_WITH_MULTIPLE_VEHICLES",
|
||||||
SELECTED_VIN_HAS_MISMATCHED_GLASS: "SELECTED_VIN_HAS_MISMATCHED_GLASS",
|
SELECTED_VIN_HAS_MISMATCHED_GLASS: "SELECTED_VIN_HAS_MISMATCHED_GLASS",
|
||||||
|
|
|
||||||
|
|
@ -67,6 +67,10 @@ const routingTable = function (store) {
|
||||||
scenario: navigationScenarios.CLICKED_FORWARD_WITHOUT_VIN,
|
scenario: navigationScenarios.CLICKED_FORWARD_WITHOUT_VIN,
|
||||||
destinationFmgPageValue: fmgPageValues.ESTIMATE,
|
destinationFmgPageValue: fmgPageValues.ESTIMATE,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
scenario: navigationScenarios.CLICKED_FORWARD_WITH_VERIFIED_INSURANCE,
|
||||||
|
destinationFmgPageValue: fmgPageValues.ESTIMATE,
|
||||||
|
},
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue