diff --git a/src/layouts/service-location/service-location.vue b/src/layouts/service-location/service-location.vue index 6893ad9b4..f9787a0e0 100644 --- a/src/layouts/service-location/service-location.vue +++ b/src/layouts/service-location/service-location.vue @@ -107,14 +107,27 @@ @setMobileLocation="setMobileLocationQuestions" @set-mobile-location-invalid="setMobileLocationInValid" /> - + cmsWidgetName="YourSafeliteShopWidget" /> --> + + + + @@ -137,6 +150,7 @@ import serviceZipModalQuestion from "@/layouts/service-location/service-zip-moda import mobileLocationModalQuestions from "@/layouts/service-location/mobile-location-modal-questions/mobile-location-modal-questions"; import appointmentTypeQuestion from "@/layouts/service-location/appointment-type-question/appointment-type-question"; import shopQuestion from "@/layouts/service-location/shop-question/shop-question"; +import shopQuestionPopup from "@/layouts/service-location/shop-question/shop-question-popup"; import funnelHeader from "@/fmg-components/funnel-header/funnel-header"; import navbar from "@/fmg-components/nav-bar/nav-bar"; @@ -763,6 +777,13 @@ export default { setMobileLocationInValid(isMobileLocationInValid) { this.isMobileAddressValid = !isMobileLocationInValid; }, + onShopSelected(providerNumber) { + // Find the provider object from your shopProviderData + const selectedProvider = this.shopProviderData.shopProviders.find( + (p) => p.providerNumber === providerNumber + ); + this.selectedProvider = selectedProvider; + }, }, watch: { zipCode: { @@ -814,7 +835,8 @@ export default { Form, loadingModal, contentGroupModal, - shopQuestion, + //shopQuestion, + shopQuestionPopup, }, }; diff --git a/src/layouts/service-location/service-zip-modal-question/service-zip-modal-question.vue b/src/layouts/service-location/service-zip-modal-question/service-zip-modal-question.vue index 5e7aa73e4..0bbfbadf4 100644 --- a/src/layouts/service-location/service-zip-modal-question/service-zip-modal-question.vue +++ b/src/layouts/service-location/service-zip-modal-question/service-zip-modal-question.vue @@ -49,6 +49,7 @@ import textLink from "@/ux-components/text-link/text-link"; import serviceZipQuestion from "@/layouts/service-location/service-zip-modal-question/service-zip-question/service-zip-question"; import modal from "@/digital-components/modal/modal"; import alert from "@/ux-components/alert/alert"; +import shopQuestion from "@/layouts/service-location/shop-question/shop-question"; import { getPricedMobileFeePart, @@ -245,6 +246,7 @@ export default { serviceZipQuestion, modal, alert, + // shopQuestion }, }; diff --git a/src/layouts/service-location/service-zip-modal-question/service-zip-question/service-zip-question.vue b/src/layouts/service-location/service-zip-modal-question/service-zip-question/service-zip-question.vue index 9841c5b16..a0a43dc14 100644 --- a/src/layouts/service-location/service-zip-modal-question/service-zip-question/service-zip-question.vue +++ b/src/layouts/service-location/service-zip-modal-question/service-zip-question/service-zip-question.vue @@ -8,8 +8,8 @@ cornerStyle="rounded" mask="#####" :displayQuestionText="false" - isRequired - validationRules="zip-required|zip-format" /> + :isRequired="isRequired" + :validationRules="computedValidationRules" /> + + diff --git a/src/layouts/service-location/shop-question/shop-question.vue b/src/layouts/service-location/shop-question/shop-question.vue index 5a9278d78..d1dc3a24c 100644 --- a/src/layouts/service-location/shop-question/shop-question.vue +++ b/src/layouts/service-location/shop-question/shop-question.vue @@ -20,7 +20,7 @@ v-model="selectedProviderNumber" isRequired validationRules="option-required" /> - + @click-event="getNextShopsFromList(1)" + :aria-label="showMoreShopsLinkText" /> --> @@ -41,6 +41,8 @@ import alert from "@/ux-components/alert/alert"; import buttonQuestion from "@/digital-components/button-question/button-question"; import shopListButton from "./shop-list-button/shop-list-button"; import textLink from "@/ux-components/text-link/text-link"; +//import shopQuestionPopup from "@/layouts/service-location/shop-question/shop-question-popup"; +//import serviceZipModalQuestion from "@/layouts/service-location/service-zip-modal-question/service-zip-modal-question"; // Supporting files import { defineRule } from "vee-validate"; @@ -125,7 +127,7 @@ export default { }, }, methods: { - async getNextShopsFromList(numberToGet = 3) { + async getNextShopsFromList(numberToGet = 1) { const logFirstShopsDisplayed = this.shopIndex == 0; const shopIterator = (array, n) => { @@ -234,6 +236,13 @@ export default { await nextTick(); } }, + onShopSelectedFromPopup(providerNumber) { + // Option 1: Update local state and emit up + this.$emit("shop-selected", providerNumber); + + // Option 2: If you want to update local state only, do: + // this.pendingSelectedProvider = providerNumber; + }, }, watch: { selectedAppointmentType: { @@ -258,8 +267,13 @@ export default { components: { alert, buttonQuestion, - textLink, + //textLink, + //shopQuestionPopup, + //serviceZipModalQuestion, }, + // mounted(){ + // console.log("shopProviderData" + this.shopProviderData); + // } };