fix: remove ‘add guests’ from the dropdown if it’s disabled in the booking questions (#19649)

* fix: remove ‘add guests’ from the dropdown if it’s disabled in the booking questions

* fix: remove dd guests' from the dropdown if it's
disabled in the booking questions
This commit is contained in:
Anik Dhabal Babu
2025-03-03 05:06:51 +00:00
committed by GitHub
parent 22f1060ed6
commit 615ef93572
2 changed files with 13 additions and 8 deletions
@@ -259,14 +259,18 @@ function BookingListItem(booking: BookingItemProps) {
},
icon: "map-pin" as const,
},
{
id: "add_members",
label: t("additional_guests"),
onClick: () => {
setIsOpenAddGuestsDialog(true);
},
icon: "user-plus" as const,
},
...(booking.eventType?.disableGuests
? []
: [
{
id: "add_members",
label: t("additional_guests"),
onClick: () => {
setIsOpenAddGuestsDialog(true);
},
icon: "user-plus" as const,
},
]),
];
if (booking.eventType.schedulingType === SchedulingType.ROUND_ROBIN) {
@@ -92,6 +92,7 @@ export async function getBookings({
recurringEvent: true,
currency: true,
metadata: true,
disableGuests: true,
seatsShowAttendees: true,
seatsShowAvailabilityCount: true,
eventTypeColor: true,