修复bug,添加备案号悬挂功能

This commit is contained in:
2026-04-14 07:53:29 +08:00
parent 72bf0c32b8
commit 4b545ddcf9
5 changed files with 24 additions and 16 deletions

View File

@@ -82,6 +82,15 @@ class PermissionChecker:
role = await PermissionChecker.get_user_role(user_id)
return role in ["班主任", "学习委员"]
@staticmethod
async def get_user_class_id(user_id: int) -> Optional[int]:
"""
获取用户关联的班级ID
单班级系统固定返回1
"""
# 本系统为单班级设计class_id 固定为 1
return 1
@staticmethod
async def check_can_revoke(user_id: int, record_id: int) -> bool:
"""