diff --git a/src/layouts/coverage-statement/coverage-statement.vue b/src/layouts/coverage-statement/coverage-statement.vue index d0d89d24..4d0b2f59 100644 --- a/src/layouts/coverage-statement/coverage-statement.vue +++ b/src/layouts/coverage-statement/coverage-statement.vue @@ -76,7 +76,7 @@ cmsWidgetName="DisclaimerWidget" typeStyle="caption" /> @@ -127,6 +127,9 @@ import coverageStatuses from '@/constants/coverage-statuses'; import coverageType from '@/constants/coverage-type'; const SAFELITE_PROVIDER = 'Safelite'; +const RECAL_MODAL_REF_NAME = "RecalModal"; +const DEDUCTIBLE_MODAL_REF_NAME = "DeductibleModal"; +const SITE_FOOTER_REF_NAME = "siteFooter"; export default { name: 'coverage-statement', @@ -206,7 +209,10 @@ export default { explanatoryText: 'ExplanatoryTextWidget', nextStep: 'NextStepsWidget', serviceProviderQuestion: 'ServiceProviderQuestion' - } + }, + RECAL_MODAL_REF_NAME, + DEDUCTIBLE_MODAL_REF_NAME, + SITE_FOOTER_REF_NAME }; }, computed: { @@ -328,17 +334,17 @@ export default { this.selectedProvider === SAFELITE_PROVIDER ? 'Continue with Safelite' : 'Continue'; - this.$refs.siteFooter.updateButtonText(buttonText); + this.$refs[SITE_FOOTER_REF_NAME].updateButtonText(buttonText); }, nextStepsBody(newValue, oldValue) { if (newValue !== oldValue) { - setupModalLink(this, 'RecalModal'); - setupModalLink(this, 'DeductibleModal'); + setupModalLink(this, RECAL_MODAL_REF_NAME); + setupModalLink(this, DEDUCTIBLE_MODAL_REF_NAME); } }, verifiedItacAlertBody(newValue, oldValue) { if (newValue !== oldValue) { - setupModalLink(this, 'DeductibleModal'); + setupModalLink(this, DEDUCTIBLE_MODAL_REF_NAME); } } }, diff --git a/src/layouts/provider-preference/provider-preference.vue b/src/layouts/provider-preference/provider-preference.vue index 30c9ebef..bf3f500b 100644 --- a/src/layouts/provider-preference/provider-preference.vue +++ b/src/layouts/provider-preference/provider-preference.vue @@ -32,7 +32,7 @@ ref="theForm" :validationRules="rules.optionRequired" isRequired /> @@ -86,10 +86,13 @@ import contentGroupModal from '@/iss-components/content-group-modal/content-grou const options = { SAFELITE: 'SafeliteOption', TPA: 'TPAOption' }; const RECAL_MODAL_REF_NAME = "RecalModal"; +const STEERING_MODAL_REF_NAME = "StateSteeringModal"; +const SHOP_PREFERENCE_MODAL_REF_NAME = "ShopPreferenceDrawer"; +const TPA_RECAL_MODAL_REF_NAME = "TPARecalModal"; +const SITE_FOOTER_REF_NAME = "siteFooter"; export default { name: 'provider-preference', - components: { siteFooter, siteHeader, @@ -116,21 +119,25 @@ export default { next((vm) => { vm.setCmsContent(resultMap.cmsContent); - vm.showSteeringLink = !!vm.$refs.StateSteeringModal.ModalBodyText; + vm.showSteeringLink = !!vm.$refs[STEERING_MODAL_REF_NAME].ModalBodyText; if (vm.showSteeringLink) { - vm.$refs.StateSteeringModal.openModal(); + vm.openStateSteeringModal(); } }); }, data() { return { - RECAL_MODAL_REF_NAME, selectedProvider: null, showSteeringLink: false, tpaAcknowledgement: false, rules: { optionRequired: globalRules.OPTION_REQUIRED - } + }, + RECAL_MODAL_REF_NAME, + STEERING_MODAL_REF_NAME, + SHOP_PREFERENCE_MODAL_REF_NAME, + TPA_RECAL_MODAL_REF_NAME, + SITE_FOOTER_REF_NAME }; }, computed: { @@ -229,8 +236,8 @@ export default { this.mainStore.updateIsSafeliteProvider(false); if (this.mainStore.issConfig.enableTPAFlow) { if (this.mainStore.hasRecalibrationPart) { - this.$refs.TPARecalModal.openModal(); - this.$refs.siteFooter.removeLoader(); + this.$refs[TPA_RECAL_MODAL_REF_NAME].openModal(); + this.$refs[SITE_FOOTER_REF_NAME].removeLoader(); return; } scenario = @@ -253,7 +260,7 @@ export default { } }, openStateSteeringModal() { - this.$refs.StateSteeringModal.openModal(); + this.$refs[STEERING_MODAL_REF_NAME].openModal(); } } }; diff --git a/src/layouts/service-location/service-location.vue b/src/layouts/service-location/service-location.vue index 831c826d..0bf33501 100644 --- a/src/layouts/service-location/service-location.vue +++ b/src/layouts/service-location/service-location.vue @@ -86,7 +86,7 @@ " />