diff --git a/src/layouts/service-location/shop-question/shop-question-popup.vue b/src/layouts/service-location/shop-question/shop-question-popup.vue index c6b980069..00254ff5b 100644 --- a/src/layouts/service-location/shop-question/shop-question-popup.vue +++ b/src/layouts/service-location/shop-question/shop-question-popup.vue @@ -163,16 +163,7 @@ export default { }, methods: { - openModal(event) { - if (event) event.preventDefault(); - if ( - !this.shopProviderData || - !this.shopProviderData.shopProviders || - !this.shopProviderData.shopProviders.length - ) { - // Optionally show a loading message or disable the link - return; - } + openModal() { this.$refs.shopQuestionModal.openModal(); }, async getNextShopsFromList(numberToGet = 3) { @@ -257,7 +248,7 @@ export default { this.localShopProviderData = this.shopProviderData; this.answers = []; - this.onSearchZip(); + this.updateShopsForZip(this.newZipCode); this.selectedProviderNumber = this.preSelectedProviderNumber; if ( (!this.selectedProviderNumber || @@ -273,17 +264,10 @@ export default { this.modal.closeModal(); }, onModalClosed() { - this.resetsOnZipInput(); - }, - resetsOnZipInput() { this.resetAlerts(); }, - async onSearchZip(event) { - if (event) { - event.preventDefault(); - event.stopPropagation(); - } - this.resetsOnZipInput(); + async onSearchZip() { + this.resetAlerts(); const zipCodeData = await this.getZipCodeData( this.newZipCode, "service-location"