fix: advanced text filters getBookings with kysely (#21143)

This commit is contained in:
Morgan authored and GitHub committed 2025-05-06 21:08:14 +00:00
1 parent 37f271bd74
commit 58d5f2a17c
1 file changed
+1 -2
@@ -424,7 +424,6 @@ export async function getBookings({
"Booking.endTime",
"Booking.metadata",
"Booking.uid",
eb
.cast<Prisma.JsonValue>( // Target TypeScript type
eb.ref("Booking.responses"), // Source column
@@ -928,7 +927,7 @@ function addAdvancedAttendeeWhereClause(
isAttendeeTableJoined: boolean
) {
let fullQuery = query.$if(!isAttendeeTableJoined, (eb) =>
eb.innerJoin("Attendee", "Attendee.id", "Booking.id")
eb.innerJoin("Attendee", "Attendee.bookingId", "Booking.id")
) as SelectQueryBuilder<
DB,
"Booking" | "Attendee",