diff --git a/src/layouts/schedule/schedule.vue b/src/layouts/schedule/schedule.vue
index 24635a1f5..67056c67d 100644
--- a/src/layouts/schedule/schedule.vue
+++ b/src/layouts/schedule/schedule.vue
@@ -116,6 +116,16 @@
+
{
@@ -835,9 +847,88 @@ export default {
);
}
},
+ durationTextBlockCopy() {
+ console.log("durationTextBlockCopy", this.appointmentType, this.getServiceMinutesMax, this.getServiceMinutesMin);
+ if (this.appointmentType === AppointmentTypeStrings.MOBILE) {
+ return this.mobileDurationText;
+ } else if (this.appointmentType === AppointmentTypeStrings.IN_SHOP) {
+ return this.inshopDurationText;
+ } else if (
+ this.appointmentType === AppointmentTypeStrings.IN_SHOP_OR_DROP_OFF ||
+ this.appointmentType === AppointmentTypeStrings.DROP_OFF
+ ) {
+ return this.getDurationTextBlockCopyForInshopOrDropoff(this.selectedTimeSlotInfo.timeSlot.routeCode);
+ }
+ return null;
+ },
+ isSameDay() {
+ const todaysDate = new Date().toISOString().split("T")[0];
+ return this.selectedDate === todaysDate;
+ },
+ dropOffDurationText() {
+ return this.getCmsContent("DropOffTimeSlotModal", cmsWidgetFieldMappings.DURATION);
+ },
+ sameDayDropoffDurationText() {
+ return this.getCmsContent(
+ "SameDayDropOffTimeSlotModal",
+ cmsWidgetFieldMappings.DURATION
+ );
+ },
+ overnightDropoffDurationText() {
+ return this.getCmsContent(
+ "OvernightDropOffTimeSlotModal",
+ cmsWidgetFieldMappings.DURATION
+ );
+ },
+ inshopDurationText() {
+ const inshopDurationTextWithoutTime = this.getCmsContent(
+ "TimeSlotModalQuestion",
+ cmsWidgetFieldMappings.DURATION
+ );
+
+ const inshopDurationTime = getDisplayTextForDurationLength(
+ this.getServiceMinutesMin,
+ this.getServiceMinutesMax
+ );
+
+ if (this.getServiceMinutesMin && this.getServiceMinutesMax) {
+ return `${inshopDurationTextWithoutTime} ${inshopDurationTime}`;
+ }
+
+ return null;
+ },
+ mobileDurationText() {
+ const mobileDurationTextWithoutTime = this.getCmsContent(
+ "TimeSlotModalQuestion",
+ cmsWidgetFieldMappings.DURATION
+ );
+
+ const mobileDurationTime = getDisplayTextForDurationLength(
+ this.getServiceMinutesMin,
+ this.getServiceMinutesMax
+ );
+
+ if (this.getServiceMinutesMin && this.getServiceMinutesMax) {
+ return `${mobileDurationTextWithoutTime} ${mobileDurationTime}`;
+ }
+
+ return null;
+ },
},
methods: {
splitCopyOnCMSPlaceHolder,
+ getDurationTextBlockCopyForInshopOrDropoff(selectedRouteCode) {
+ if (selectedRouteCode?.includes(RouteCodeFlags.OVERNIGHT_DROP_OFF)) {
+ return this.overnightDropoffDurationText;
+ } else if (selectedRouteCode?.includes(RouteCodeFlags.ALL_DAY_DROP_OFF)) {
+ if (this.isSameDay) {
+ return this.sameDayDropoffDurationText;
+ } else {
+ return this.dropOffDurationText;
+ }
+ }
+ return this.inshopDurationText;
+ },
arePagePrerequisitesValid() {
const paymentInfo = store.getters.payment.isInsurance !== null;
const damageInfo =