feat: v2 api endpoints and hooks to list private and public event types of user (#14192)
* refactor: extract getEventTypeByViewer for private user dashboard event types * refactor: extract getEventTypesPublic for public event types to book * refactor: group event-types lib functions in single folder * refactor: rename getEventTypeByViewer to getEventTypesByViewer * feat: add event type helpers from lib to platform libraries * feat: v2 endpoint for private event types * driveby:fix: fixed date in docs instead of being re-generated * feature: endpoint to fetch public endpoints * fix: getting private event types * tests: fetch private event types * tests: fetch private event types * feat: hooks for public and private events * fix: yarn test * tests: IMO better mocking * refactor: track dynamic prop in react query * fix: distinct query key for public events * fix: username in query key and example app demo * fix: swagger for endpoint get public event input --------- Co-authored-by: Morgan Vernay <[email protected]> Co-authored-by: Morgan <[email protected]>
This commit is contained in:
24 files changed
+680
-410
No files matched your search
@@ -11,7 +11,13 @@ export type UpdateScheduleOutputType = Awaited<
|
||||
typeof import("@calcom/trpc/server/routers/viewer/availability/schedule/update.handler").updateHandler
|
||||
>
|
||||
>;
|
||||
export { getEventTypeById } from "@calcom/lib/getEventTypeById";
|
||||
export { getEventTypeById } from "@calcom/lib/event-types/getEventTypeById";
|
||||
export { getEventTypesByViewer } from "@calcom/lib/event-types/getEventTypesByViewer";
|
||||
export { getEventTypesPublic } from "@calcom/lib/event-types/getEventTypesPublic";
|
||||
|
||||
export type { EventType } from "@calcom/lib/event-types/getEventTypeById";
|
||||
export type { EventTypesByViewer } from "@calcom/lib/event-types/getEventTypesByViewer";
|
||||
export type { EventTypesPublic } from "@calcom/lib/event-types/getEventTypesPublic";
|
||||
|
||||
export type PublicEventType = Awaited<ReturnType<typeof getPublicEvent>>;
|
||||
export { getPublicEvent };
|
||||
@@ -26,7 +32,6 @@ export { getAvailableSlots };
|
||||
export type AvailableSlotsType = Awaited<ReturnType<typeof getAvailableSlots>>;
|
||||
export { handleNewRecurringBooking } from "@calcom/features/bookings/lib/handleNewRecurringBooking";
|
||||
|
||||
export type { EventType } from "@calcom/lib/getEventTypeById";
|
||||
export { getConnectedDestinationCalendars } from "@calcom/lib/getConnectedDestinationCalendars";
|
||||
export type { ConnectedDestinationCalendars } from "@calcom/lib/getConnectedDestinationCalendars";
|
||||
export { getBusyCalendarTimes } from "@calcom/core/CalendarManager";
|
||||
|
||||
Reference in new issue
Block a user