This commit is contained in:
Leah Schumann 2023-04-24 11:02:00 -04:00
parent 8ac7007a2a
commit 5933a44bc8
2 changed files with 23 additions and 10 deletions

View file

@ -67,7 +67,7 @@
modalWidgetName="MobileLocationModalWidget" />
<shopQuestion
ref="shopQuestion"
v-if="selectedAppointmentType === 'Inshop' || selectedAppointmentType === 'Dropoff'"
v-show="selectedAppointmentType === 'Inshop' || selectedAppointmentType === 'Dropoff'"
v-model="selectedShop"
:isDropoff="isDropoff"
:serviceZipCode="zipCode"

View file

@ -149,13 +149,19 @@ export default {
await this.$nextTick();
if (this.shopIndex == this.shops.length) {
this.displaySeeMoreLocationsLink = false;
} else {
this.displaySeeMoreLocationsLink = true;
}
await this.$nextTick();
const container = document.getElementsByClassName("page-container-grouped-styles")[0];
container.scrollTo({ top: container.scrollHeight, left: 0, behavior: "smooth" });
if (this.shopIndex == this.shops.length) {
this.displaySeeMoreLocationsLink = false;
}
},
resetShopList() {
this.answers = [];
@ -167,12 +173,12 @@ export default {
this.$refs.buttonQuestion.resetField();
},
},
mounted() {
console.log(this.shopQuestionData)
this.shops = this.shopQuestionData;
this.getNextShopsFromList()
console.log(this.shops)
},
// mounted() {
// console.log(this.shopQuestionData);
// this.shops = this.shopQuestionData;
// this.getNextShopsFromList();
// console.log(this.shops);
// },
watch: {
serviceZipCode: {
async handler() {
@ -198,6 +204,13 @@ export default {
this.resetShopList();
},
},
shopQuestionData: {
handler(newValue) {
console.log(newValue)
this.shops = newValue;
this.getNextShopsFromList();
},
}
},
};
</script>