feat: add event-scoped schedule deletion and import date guard
This commit is contained in:
1 parent
ef0121a3e4
commit
5c93d4a0cb
12 files changed
+2034
-14
No files matched your search
@@ -3,6 +3,7 @@ import type {
|
||||
Checkin,
|
||||
Connection,
|
||||
Contact,
|
||||
DeleteEventScheduleResult,
|
||||
Event,
|
||||
EventFeedback,
|
||||
ExcelSyncResult,
|
||||
@@ -319,6 +320,10 @@ export async function deactivateEvent(id: string): Promise<void> {
|
||||
if (error) throw new ApiError(error.message);
|
||||
}
|
||||
|
||||
export async function deleteEventSchedule(eventId: string): Promise<DeleteEventScheduleResult> {
|
||||
return await rpc<DeleteEventScheduleResult>('delete_event_schedule', { p_event_id: eventId });
|
||||
}
|
||||
|
||||
// ---- Points ------------------------------------------------------------------
|
||||
|
||||
/** Admin manual points adjustment for the active event (audited as 'admin'). */
|
||||
|
||||
@@ -238,6 +238,18 @@ export interface SessionSpeaker {
|
||||
contact_email: string;
|
||||
}
|
||||
|
||||
export interface DeleteEventScheduleResult {
|
||||
event_id: string;
|
||||
event_name: string;
|
||||
slots_deleted: number;
|
||||
sessions_deleted: number;
|
||||
session_speakers_deleted: number;
|
||||
preferences_deleted: number;
|
||||
checkins_deleted: number;
|
||||
feedback_deleted: number;
|
||||
material_paths_unpurged: number;
|
||||
}
|
||||
|
||||
export type ConnectionStatus = 'pending' | 'accepted' | 'rejected';
|
||||
|
||||
export interface Connection {
|
||||
|
||||
Reference in new issue
Block a user