updates to navigation
This commit is contained in:
parent
85c29e04be
commit
7d21d3b697
1 changed files with 11 additions and 5 deletions
|
|
@ -114,6 +114,7 @@ import { useMainStore } from '@/store/index.js';
|
||||||
import vehicleQuestionsMixin from '@/mixins/vehicle-questions-mixin.js';
|
import vehicleQuestionsMixin from '@/mixins/vehicle-questions-mixin.js';
|
||||||
import globalRules from '@/constants/global-rules.js';
|
import globalRules from '@/constants/global-rules.js';
|
||||||
import baseFormMixin from '@/mixins/base-form-mixin.js';
|
import baseFormMixin from '@/mixins/base-form-mixin.js';
|
||||||
|
import { navigationScenarios } from '@/router/router-constants/navigation-scenarios.js';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'coverage-statement',
|
name: 'coverage-statement',
|
||||||
|
|
@ -125,7 +126,8 @@ export default {
|
||||||
recalModal,
|
recalModal,
|
||||||
alert,
|
alert,
|
||||||
contentGroupModal,
|
contentGroupModal,
|
||||||
buttonQuestion
|
buttonQuestion,
|
||||||
|
navigationScenarios
|
||||||
},
|
},
|
||||||
mixins: [baseFormMixin, vehicleQuestionsMixin],
|
mixins: [baseFormMixin, vehicleQuestionsMixin],
|
||||||
async beforeRouteEnter(to, from, next) {
|
async beforeRouteEnter(to, from, next) {
|
||||||
|
|
@ -350,20 +352,24 @@ export default {
|
||||||
},
|
},
|
||||||
async navigateForward() {
|
async navigateForward() {
|
||||||
if (this.coverageUnverified || this.verifiedDeductible) {
|
if (this.coverageUnverified || this.verifiedDeductible) {
|
||||||
this.$router.navigate(this.navigationScenarios.CLICKED_FORWARD,
|
this.$router.navigate(navigationScenarios.CLICKED_FORWARD,
|
||||||
this.$route);
|
this.$route);
|
||||||
} else if (this.verifiedITAC || this.verifiedNoComp) {
|
} else if (this.verifiedITAC || this.verifiedNoComp) {
|
||||||
if (this.selectedProvider === 'Safelite') {
|
if (this.selectedProvider === 'Safelite') {
|
||||||
this.$router.navigate(this.navigationScenarios.CLICKED_FORWARD_WITH_SAFELITE,
|
this.$router.navigate(navigationScenarios.CLICKED_FORWARD_WITH_SAFELITE,
|
||||||
this.$route);
|
this.$route);
|
||||||
} else if (this.selectedProvider === 'Other' && this.mainStore.issConfig.enableTPAFlow) {
|
} else if (this.selectedProvider === 'Other' && this.mainStore.issConfig.enableTPAFlow) {
|
||||||
this.$router.navigate(this.navigationScenarios.CLICKED_FORWARD_WITH_TPA_ENABLED,
|
this.$router.navigate(navigationScenarios.CLICKED_FORWARD_WITH_TPA_ENABLED,
|
||||||
this.$route);
|
this.$route);
|
||||||
} else {
|
} else {
|
||||||
this.$router.navigate(this.navigationScenarios.CLICKED_FORWARD_WITH_TPA_DISABLED,
|
this.$router.navigate(navigationScenarios.CLICKED_FORWARD_WITH_TPA_DISABLED,
|
||||||
this.$route);
|
this.$route);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else {
|
||||||
|
this.$router.navigate(navigationScenarios.CLICKED_FORWARD_WITH_INVALID_STATE,
|
||||||
|
this.$route);
|
||||||
|
}
|
||||||
},
|
},
|
||||||
openModalAction(modalName) {
|
openModalAction(modalName) {
|
||||||
this.$refs[modalName.args].openModal();
|
this.$refs[modalName.args].openModal();
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue