fix: booker atom seated events reservation (#21339)
* fix: reserving first seated booking slot * fix: input type in useReserveSlot * fix: handleReserveSlot submit bookingUid to api * null -> undefined * dont touch web app
This commit is contained in:
1 parent
a5b684af1f
commit
86918b03cf
5 files changed
+12
-8
No files matched your search
@@ -136,7 +136,8 @@ export const AvailableTimeSlots = ({
|
||||
schedule?.invalidate();
|
||||
}
|
||||
setTentativeSelectedTimeslots([]);
|
||||
setSelectedTimeslot(time);
|
||||
// note(Lauris): setting setSeatedEventData before setSelectedTimeslot so that in useSlots we have seated event data available
|
||||
// and only then we invoke handleReserveSlot that is triggered by the changes in setSelectedTimeslot.
|
||||
if (seatsPerTimeSlot) {
|
||||
setSeatedEventData({
|
||||
seatsPerTimeSlot,
|
||||
@@ -145,6 +146,7 @@ export const AvailableTimeSlots = ({
|
||||
showAvailableSeatsCount,
|
||||
});
|
||||
}
|
||||
setSelectedTimeslot(time);
|
||||
const isTimeSlotAvailable = !unavailableTimeSlots.includes(time);
|
||||
if (skipConfirmStep && isTimeSlotAvailable) {
|
||||
onSubmit(time);
|
||||
|
||||
Reference in new issue
Block a user