feat: authentication secured event types (#23217)
* feat: EventType bookingRequiresAuthentication column * feat: toggle EventType bookingRequiresAuthentication via api * feat: check bookingRequiresAuthentication when booking * docs: v2 swagger * fix: ts error * refactor: use Forbidden exception instead of Unauthorized * refactor: use findFirst instead of unique * fix: only count accepted memberships * fix: orgs schedules docs * regenerate docs * chore: update platform libraries * fix: unit test * fix: e2e test
This commit is contained in:
1 parent
aea6e105e6
commit
e0dc2ba03a
25 files changed
+810
-17
No files matched your search
+2
@@ -0,0 +1,2 @@
|
||||
-- AlterTable
|
||||
ALTER TABLE "EventType" ADD COLUMN "bookingRequiresAuthentication" BOOLEAN NOT NULL DEFAULT false;
|
||||
@@ -228,6 +228,8 @@ model EventType {
|
||||
restrictionSchedule Schedule? @relation("restrictionSchedule", fields: [restrictionScheduleId], references: [id])
|
||||
hostGroups HostGroup[]
|
||||
|
||||
bookingRequiresAuthentication Boolean @default(false)
|
||||
|
||||
@@unique([userId, slug])
|
||||
@@unique([teamId, slug])
|
||||
@@unique([userId, parentId])
|
||||
|
||||
@@ -681,6 +681,7 @@ export const allManagedEventTypeProps: { [k in keyof Omit<Prisma.EventTypeSelect
|
||||
rescheduleWithSameRoundRobinHost: true,
|
||||
maxLeadThreshold: true,
|
||||
customReplyToEmail: true,
|
||||
bookingRequiresAuthentication: true,
|
||||
};
|
||||
|
||||
// All properties that are defined as unlocked based on all managed props
|
||||
|
||||
Reference in new issue
Block a user