Merge branch 'release/2025.07.31' into feature/CASH-845-stage-6
This commit is contained in:
commit
e552d37031
2 changed files with 65 additions and 39 deletions
|
|
@ -222,7 +222,7 @@ export default {
|
||||||
},
|
},
|
||||||
premiumAppointmentButtonText() {
|
premiumAppointmentButtonText() {
|
||||||
return this.getCmsContent(
|
return this.getCmsContent(
|
||||||
this.dropOffOrPickATimeQuestionCmsWidgetName,
|
this.mobilePremiumCmsWidgetName,
|
||||||
cmsWidgetFieldMappings.TIME_SLOT_BUTTON
|
cmsWidgetFieldMappings.TIME_SLOT_BUTTON
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
|
@ -544,7 +544,8 @@ export default {
|
||||||
},
|
},
|
||||||
selectedDate: {
|
selectedDate: {
|
||||||
handler() {
|
handler() {
|
||||||
this.selectedRouteCode = null;
|
this.selectedAnswerForDropOffOrInshop = null;
|
||||||
|
this.selectedAnswerForTimeSlots = null;
|
||||||
this.autoSelectTimeSlotIfOnlyOneIsAvailable();
|
this.autoSelectTimeSlotIfOnlyOneIsAvailable();
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -31,43 +31,48 @@
|
||||||
:isRequired="false"
|
:isRequired="false"
|
||||||
:validationRules="''" />
|
:validationRules="''" />
|
||||||
</form>
|
</form>
|
||||||
<alert
|
<div v-show="isLoading" class="loader-wrapper">
|
||||||
ref="alertInvalidZip"
|
<loader loaderColor="blue" loaderPosition="center" />
|
||||||
v-if="displayInvalidZipAlert"
|
</div>
|
||||||
class="mb-4"
|
<div v-show="!isLoading">
|
||||||
cmsWidgetName="AlertInvalidZipWidget"
|
<alert
|
||||||
alertClass="alert-danger"
|
ref="alertInvalidZip"
|
||||||
v-bind:isDismissible="false" />
|
v-if="displayInvalidZipAlert"
|
||||||
<alert
|
class="mb-4"
|
||||||
ref="alertNoShops"
|
cmsWidgetName="AlertInvalidZipWidget"
|
||||||
class="my-5"
|
alertClass="alert-danger"
|
||||||
cmsWidgetName="AlertNoShopsWidget"
|
v-bind:isDismissible="false" />
|
||||||
v-if="displayNoShopsAlert"
|
<alert
|
||||||
alertClass="alert-warning" />
|
ref="alertNoShops"
|
||||||
<div v-if="!displayInvalidZipAlert">
|
class="my-5"
|
||||||
<buttonQuestion
|
cmsWidgetName="AlertNoShopsWidget"
|
||||||
ref="buttonQuestion"
|
v-if="displayNoShopsAlert"
|
||||||
buttonTypeString="shopListButton"
|
alertClass="alert-warning" />
|
||||||
:buttonTypeObject="shopListButton"
|
<div v-if="!displayInvalidZipAlert">
|
||||||
class="radioQuestion"
|
<buttonQuestion
|
||||||
:questionText="questionText"
|
ref="buttonQuestion"
|
||||||
:answers="answers"
|
buttonTypeString="shopListButton"
|
||||||
groupName="chooseShop"
|
:buttonTypeObject="shopListButton"
|
||||||
textPosition="text-start"
|
class="radioQuestion"
|
||||||
v-model="localSelectedProviderNumber"
|
:questionText="questionText"
|
||||||
isRequired
|
:answers="answers"
|
||||||
:validationRules="this.localSelectedProviderNumber ? '' : 'option-required'" />
|
groupName="chooseShop"
|
||||||
<div class="show-more-shops-link">
|
textPosition="text-start"
|
||||||
<textLink
|
v-model="localSelectedProviderNumber"
|
||||||
v-if="displaySeeMoreLocationsLink"
|
isRequired
|
||||||
ref="showMoreShopsLink"
|
:validationRules="this.localSelectedProviderNumber ? '' : 'option-required'" />
|
||||||
id="showMoreShopsId2"
|
<div class="show-more-shops-link">
|
||||||
cmsWidgetName="ShowMoreShopsLinkWidget"
|
<textLink
|
||||||
linkType="text"
|
v-if="displaySeeMoreLocationsLink"
|
||||||
:text="showMoreShopsLinkText"
|
ref="showMoreShopsLink"
|
||||||
href="#!"
|
id="showMoreShopsId2"
|
||||||
@click-event="updateShopListWithNextShops()"
|
cmsWidgetName="ShowMoreShopsLinkWidget"
|
||||||
:aria-label="showMoreShopsLinkText" />
|
linkType="text"
|
||||||
|
:text="showMoreShopsLinkText"
|
||||||
|
href="#!"
|
||||||
|
@click-event="updateShopListWithNextShops()"
|
||||||
|
:aria-label="showMoreShopsLinkText" />
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</modal>
|
</modal>
|
||||||
|
|
@ -87,6 +92,7 @@ import { defineRule } from "vee-validate";
|
||||||
import { required } from "@/helpers/validation-rules";
|
import { required } from "@/helpers/validation-rules";
|
||||||
import { errorMessages } from "@/constants/error-messages";
|
import { errorMessages } from "@/constants/error-messages";
|
||||||
import baseMixin from "@/mixins/base-mixin.js";
|
import baseMixin from "@/mixins/base-mixin.js";
|
||||||
|
import loader from "@/ux-components/loader/loader";
|
||||||
|
|
||||||
import { AppointmentTypeStrings } from "@/constants/schedule-constants";
|
import { AppointmentTypeStrings } from "@/constants/schedule-constants";
|
||||||
|
|
||||||
|
|
@ -109,6 +115,7 @@ export default {
|
||||||
localShopProviderData: this.shopProviderDataFromParent,
|
localShopProviderData: this.shopProviderDataFromParent,
|
||||||
localSelectedProviderNumber: null,
|
localSelectedProviderNumber: null,
|
||||||
zipCodeData: null,
|
zipCodeData: null,
|
||||||
|
isLoading: false,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
props: {
|
props: {
|
||||||
|
|
@ -160,6 +167,7 @@ export default {
|
||||||
},
|
},
|
||||||
isModalFooterButtonDisabled() {
|
isModalFooterButtonDisabled() {
|
||||||
return (
|
return (
|
||||||
|
this.isLoading ||
|
||||||
this.displayInvalidZipAlert ||
|
this.displayInvalidZipAlert ||
|
||||||
this.displayNoShopsAlert ||
|
this.displayNoShopsAlert ||
|
||||||
!this.localSelectedProviderNumber
|
!this.localSelectedProviderNumber
|
||||||
|
|
@ -250,6 +258,13 @@ export default {
|
||||||
},
|
},
|
||||||
async onSearchZip(event) {
|
async onSearchZip(event) {
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
|
if (!this.localZipCode) {
|
||||||
|
this.zipCodeData = {
|
||||||
|
isValid: false,
|
||||||
|
};
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
this.isLoading = true;
|
||||||
this.zipCodeData = await this.getZipCodeData(this.localZipCode, "service-location");
|
this.zipCodeData = await this.getZipCodeData(this.localZipCode, "service-location");
|
||||||
// Add zipCode to zipCodeData as it does not come back from endpoint
|
// Add zipCode to zipCodeData as it does not come back from endpoint
|
||||||
this.zipCodeData.zipCode = this.localZipCode;
|
this.zipCodeData.zipCode = this.localZipCode;
|
||||||
|
|
@ -271,8 +286,11 @@ export default {
|
||||||
this.localShopProviderData = result.data;
|
this.localShopProviderData = result.data;
|
||||||
this.numberOfShopsToDisplay = 3;
|
this.numberOfShopsToDisplay = 3;
|
||||||
this.updateShopsForZip();
|
this.updateShopsForZip();
|
||||||
|
this.isLoading = false;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
this.isLoading = false;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
updateShopsForZip() {
|
updateShopsForZip() {
|
||||||
|
|
@ -317,6 +335,7 @@ export default {
|
||||||
serviceZipQuestion,
|
serviceZipQuestion,
|
||||||
buttonQuestion,
|
buttonQuestion,
|
||||||
alert,
|
alert,
|
||||||
|
loader,
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
@ -444,4 +463,10 @@ export default {
|
||||||
display: block;
|
display: block;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
.loader-wrapper {
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
max-width: 100%;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue