From b2615f3db8244c961daae68ad613fd2c20d9fcab Mon Sep 17 00:00:00 2001 From: Scott Kiener Date: Wed, 9 Jul 2025 09:29:37 -0400 Subject: [PATCH] CASH-814 | Cleanup pt 1 --- .../time-slot-question/time-slot-question.vue | 101 +++++++++--------- 1 file changed, 48 insertions(+), 53 deletions(-) diff --git a/src/layouts/schedule/time-slot-question/time-slot-question.vue b/src/layouts/schedule/time-slot-question/time-slot-question.vue index 80d22cae5..accba205c 100644 --- a/src/layouts/schedule/time-slot-question/time-slot-question.vue +++ b/src/layouts/schedule/time-slot-question/time-slot-question.vue @@ -196,26 +196,25 @@ export default { let appointmentTypeCmsWidgetName; if (this.appointmentType === AppointmentTypeStrings.IN_SHOP_OR_DROP_OFF) { - // This is planned to be used again for drop-off - // Leaving this here with that in mind, move logic from the final else in here - // and only apply it when a dropoff slot is selected return null; - } else if (this.appointmentType === AppointmentTypeStrings.MOBILE) { + // This is planned to be used again for drop-off + // Wrote this to be ready for that eventuality, is untested and no HTML work done yet + + // if (this.selectedRouteCode == null || !this.isDropOffRouteCode(this.selectedRouteCode)) { + // return null; + // } else { + // appointmentTypeCmsWidgetName = + // this.getRelevantDropOffCmsWidgetNameForSelectedTimeSlot( + // this.selectedRouteCode, + // true + // ); + // } + } else { appointmentTypeCmsWidgetName = this.selectedRouteCode?.includes( PREMIUM_TIME_SLOT_ID_FLAG ) ? this.mobilePremiumCmsWidgetName : this.mobileCmsWidgetName; - } else { - if (!this.selectedRouteCode) { - return null; - } else { - appointmentTypeCmsWidgetName = - this.getRelevantDropOffCmsWidgetNameForSelectedTimeSlot( - this.selectedRouteCode, - true - ); - } } return this.getCmsContent( @@ -223,12 +222,6 @@ export default { cmsWidgetFieldMappings.SUPPLEMENTAL_INFORMATION ); }, - footerCloseButtonText() { - return this.getCmsContent( - this.cmsWidgetName, - cmsWidgetFieldMappings.MODAL_CLOSE_BUTTON - ); - }, dropOffOrPickATimeQuestionLabelText() { return this.getCmsContent(this.dropOffOrPickATimeQuestionCmsWidgetName, "QuestionText"); }, @@ -260,38 +253,40 @@ export default { cmsWidgetFieldMappings.TIME_SLOT_BUTTON ); }, - dropoffDisclaimerText() { - return this.getCmsContent(this.dropoffCmsWidgetName, cmsWidgetFieldMappings.DISCLAIMER); - }, - sameDayDropOffDisclaimerText() { - return this.getCmsContent( - this.sameDayDropOffCmsWidgetName, - cmsWidgetFieldMappings.DISCLAIMER - ); - }, - overnightDropOffDisclaimerText() { - return this.getCmsContent( - this.overnightDropOffCmsWidgetName, - cmsWidgetFieldMappings.DISCLAIMER - ); - }, - disclaimerTextBlockCopy() { - if (this.appointmentType === AppointmentTypeStrings.DROP_OFF) { - if (this.selectedRouteCode?.includes(RouteCodeFlags.ALL_DAY_DROP_OFF)) { - if (this.isSameDay) { - return this.sameDayDropOffDisclaimerText; - } else { - return this.dropoffDisclaimerText; - } - } else if (this.selectedRouteCode?.includes(RouteCodeFlags.OVERNIGHT_DROP_OFF)) { - return this.overnightDropOffDisclaimerText; - } else { - return null; - } - } else { - return null; - } - }, + // None of this is used, but apparently could be re-activated if we go back to + // complete parity with Heritage. If that plan is dropped, delete this + // dropoffDisclaimerText() { + // return this.getCmsContent(this.dropoffCmsWidgetName, cmsWidgetFieldMappings.DISCLAIMER); + // }, + // sameDayDropOffDisclaimerText() { + // return this.getCmsContent( + // this.sameDayDropOffCmsWidgetName, + // cmsWidgetFieldMappings.DISCLAIMER + // ); + // }, + // overnightDropOffDisclaimerText() { + // return this.getCmsContent( + // this.overnightDropOffCmsWidgetName, + // cmsWidgetFieldMappings.DISCLAIMER + // ); + // }, + // disclaimerTextBlockCopy() { + // if (this.appointmentType === AppointmentTypeStrings.DROP_OFF) { + // if (this.selectedRouteCode?.includes(RouteCodeFlags.ALL_DAY_DROP_OFF)) { + // if (this.isSameDay) { + // return this.sameDayDropOffDisclaimerText; + // } else { + // return this.dropoffDisclaimerText; + // } + // } else if (this.selectedRouteCode?.includes(RouteCodeFlags.OVERNIGHT_DROP_OFF)) { + // return this.overnightDropOffDisclaimerText; + // } else { + // return null; + // } + // } else { + // return null; + // } + // }, dropOffDurationText() { return this.getCmsContent(this.dropoffCmsWidgetName, cmsWidgetFieldMappings.DURATION); }, @@ -391,6 +386,7 @@ export default { buttonLabel: buttonLabelValue, }; }); + // Only add the pick a time button if inShop timeslots are available if ( this.getAvailableTimeSlotsForInshop(this.timeSlotsForSelectedDate.timeSlots) .length !== 0 @@ -648,7 +644,6 @@ export default { }, }, components: { - // Removed modal textBlock, buttonQuestion, checkboxQuestion,