Merged in fix/BOOK-599-filter-alert-booking-flow (pull request #3314)

fix(BOOK-599): filter displayInBookingFlow alert

* fix(BOOK-599): filter displayInBookingFlow alert

* fix(BOOK-599): filter displayinbookingflow on confirmation page


Approved-by: Linus Flood
This commit is contained in:
Bianca Widstam
2025-12-08 15:00:41 +00:00
committed by Linus Flood
parent 276027045e
commit 8682e66047
2 changed files with 14 additions and 9 deletions

View File

@@ -33,8 +33,10 @@ export async function SelectRate({
isInValidFNF = cookieStore.get("sc")?.value !== "1"
}
const validAlerts = hotelData.hotel.specialAlerts.filter((alert) =>
hasOverlappingDates(alert, dt(booking.fromDate), dt(booking.toDate))
const validAlerts = hotelData.hotel.specialAlerts.filter(
(alert) =>
hasOverlappingDates(alert, dt(booking.fromDate), dt(booking.toDate)) &&
alert.displayInBookingFlow
)
return (