feat: 完善学生生命周期管理与权限范围并发布 1.4.2

This commit is contained in:
LoveChengke committed 2026-10-23 22:55:21 +08:00
1 parent 6347d1e5aa
commit 24e8dd902b
92 files changed
+6801 -2255

No files matched your search

+3 -3
View File
@@ -1,7 +1,7 @@
/** 所有在读入口共用;归档/转出专页显式读取历史状态。 */
export function activeStudentWhere() {
return { status: { notIn: ['transferred', 'inactive'] } };
return { status: 'active', archivedYearId: null };
}
export function isActiveStudent(student: { status: string }) {
return !activeStudentWhere().status.notIn.includes(student.status);
export function isActiveStudent(student: { status: string; archivedYearId?: string | null }) {
return student.status === 'active' && !student.archivedYearId;
}