forked from wangziqi/gongxue-base
feat: complete remaining PRD tasks — RBAC nodes and staff split, schedule month view, auto-generate attendance from schedules, plus fix TypeORM name
This commit is contained in:
@@ -47,12 +47,12 @@ export class CampusScope {
|
||||
if (ids.length === 0) {
|
||||
// Non-super-admin with no scoping → match nothing, never leak unfiltered data
|
||||
if (!this.isSuperAdmin) {
|
||||
return { ...where, departmentId: In([]) } as unknown as T;
|
||||
return { ...where, departmentId: In([]) };
|
||||
}
|
||||
return where;
|
||||
}
|
||||
|
||||
return { ...where, departmentId: In(ids) } as unknown as T;
|
||||
return { ...where, departmentId: In(ids) };
|
||||
}
|
||||
|
||||
/** Returns department IDs for QueryBuilder .andWhere() usage. null = no filtering needed. */
|
||||
|
||||
Reference in New Issue
Block a user