Button copy change & immediately continue (from modal) on Schedule page
This commit is contained in:
hiteshkumar87 2024-01-03 16:35:53 +05:30
parent a1ab29711e
commit 2e422019e6
4 changed files with 12 additions and 4 deletions

View file

@ -48,7 +48,8 @@
selectableDatesData.estimatedServiceMinutesMaximum
"
@time-slot-modal-closed="timeSlotModalClosed"
validationRules="time-slot-selection-required" />
validationRules="time-slot-selection-required"
@ForwardClicked="forwardButtonAction" />
<navbar
cmsWidgetName="FunnelFooterWidget"
ref="navbar"

View file

@ -97,6 +97,7 @@ describe("time-slot-modal-question.vue", () => {
//Assert
expect(wrapper.emitted()["update:modelValue"]).toEqual(expectedEmit);
expect(wrapper.emitted()).toHaveProperty("ForwardClicked");
});
});

View file

@ -82,7 +82,7 @@ defineRule("time-slot-required", required(errorMessages.OPTION_REQUIRED));
export default {
name: "time-slot-modal-question",
emits: ["update:modelValue"],
emits: ["update:modelValue", "ForwardClicked"],
props: {
modelValue: {
type: Object,
@ -343,13 +343,15 @@ export default {
},
onModalClosed() {
this.$emit("time-slot-modal-closed");
this.selectedRouteCode = this.getSelectedRouteCode();
this.modal.resetForm();
},
async setSelectedTimeSlot() {
this.$emit(
"update:modelValue",
this.getSelectedTimeSlotInfoObject(this.selectedRouteCode)
);
this.closeModal();
this.$emit("ForwardClicked");
},
getRelevantDropOffCmsWidgetNameForSelectedTimeSlot(
selectedRouteCode,

View file

@ -169,7 +169,11 @@ router.beforeEach(async (to, from, next) => {
if (fromQueryPage === undefined) {
showFmgLoadingModal(true);
}
// remove modal backdrop if one exists
let modalBackground = document.querySelector(".modal-backdrop");
if (modalBackground) {
modalBackground.remove();
}
const toQueryPage = to.query?.fmgPage;
const notToPIAReturn = toQueryPage != fmgPageValues.PAYMENT_PIA_RETURN;
const isInIframe = window !== window.top;