mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-12-03 17:41:51 +00:00
fix(bookings): a hotel booking's card shows check-in and check-out when only the stay has them
The edit form fell back to the linked stay's times, the cards read only the booking's metadata, so a hotel showed 15:00 and 11:00 when edited and no times in the list. The reservation list now carries the stay's check-in window and check-out, and the desktop facts and the phone card fall back to them. On the phone they come first, so a price or a seat cannot push them off the card.
This commit is contained in:
@@ -190,6 +190,10 @@ export const reservationSchema = z.object({
|
||||
accommodation_name: z.string().nullable().optional(),
|
||||
accommodation_start_day_id: z.number().nullable().optional(),
|
||||
accommodation_end_day_id: z.number().nullable().optional(),
|
||||
// The stay's check-in window and check-out, for a hotel booking whose own metadata has none.
|
||||
accommodation_check_in: z.string().nullable().optional(),
|
||||
accommodation_check_in_end: z.string().nullable().optional(),
|
||||
accommodation_check_out: z.string().nullable().optional(),
|
||||
day_positions: z.record(z.string(), z.number()).nullable().optional(),
|
||||
endpoints: z.array(reservationEndpointSchema).optional(),
|
||||
// Trip members / named guests this booking is for (#1517). Joined in listReservations.
|
||||
|
||||
Reference in New Issue
Block a user