diff --git a/src/layouts/service-location/service-location.vue b/src/layouts/service-location/service-location.vue index 88cedcee2..b85790c28 100644 --- a/src/layouts/service-location/service-location.vue +++ b/src/layouts/service-location/service-location.vue @@ -111,7 +111,8 @@ :selectedAppointmentType="selectedAppointmentType" :shopProviderData="shopProviderData" :isDisplayed="isShopQuestionDisplayed" - cmsWidgetName="ShopQuestionWidget" /> + cmsWidgetName="ShopQuestionWidget" + :isInshopOnly="isInshopOnly" /> @@ -415,6 +416,11 @@ export default { isNoComp() { return store.getters.order.policy.isNoComp; }, + isInshopOnly() { + return ( + this.isServiceableInshop && !this.isServiceableMobile && !this.isServiceableDropoff + ); + }, }, methods: { arePagePrerequisitesValid() { diff --git a/src/layouts/service-location/shop-question/shop-question.vue b/src/layouts/service-location/shop-question/shop-question.vue index 417a3b4c4..76d59be7c 100644 --- a/src/layouts/service-location/shop-question/shop-question.vue +++ b/src/layouts/service-location/shop-question/shop-question.vue @@ -77,6 +77,7 @@ export default { cmsWidgetName: String, validationRules: String, isDisplayed: Boolean, + isInshopOnly: Boolean, }, computed: { questionText() { @@ -233,10 +234,13 @@ export default { // nothing to do with this component. We could mitigate this by showing / hiding this component with v-if but that messes // up the component initialization on page load. async handler() { - this.resetAnswers(); + //We do not need to run this handler in case of Inshop only else it will ended running twice function getNextShopsFromList and will cause pagination + if (!this.isInshopOnly) { + this.resetAnswers(); - await nextTick(); - this.getNextShopsFromList(); + await nextTick(); + this.getNextShopsFromList(); + } }, }, shopProviders: {