This commit is contained in:
@@ -722,6 +722,21 @@ export const apiFetchOnlineStudents = async (rkId: number): Promise<{ onlineStud
|
||||
return res.json();
|
||||
};
|
||||
|
||||
export interface ScheduleConflictItem {
|
||||
studentRkId: number;
|
||||
fullName: string;
|
||||
studentCode: string;
|
||||
conflictClassRkId: number;
|
||||
conflictClassName: string;
|
||||
conflictClassCode: string;
|
||||
}
|
||||
|
||||
export const apiFetchScheduleConflicts = async (rkId: number): Promise<{ conflicts: ScheduleConflictItem[]; ok: boolean }> => {
|
||||
const res = await staffFetch(`/classes/${rkId}/schedule-conflicts`);
|
||||
if (!res.ok) throw new Error('Failed to check schedule conflicts');
|
||||
return res.json();
|
||||
};
|
||||
|
||||
export const apiFetchClassCourses = async (rkId: number): Promise<{
|
||||
data: ClassCourseItem[];
|
||||
source?: string;
|
||||
|
||||
Reference in New Issue
Block a user