feat: cms users institution department manager
This commit is contained in:
@@ -100,7 +100,8 @@ def register(request):
|
||||
|
||||
department = None
|
||||
if department_name:
|
||||
qs = Department.objects.filter(name=department_name, institution=institution)
|
||||
# 科室为全局表,按名称解析(与机构无关)
|
||||
qs = Department.objects.filter(name=department_name)
|
||||
cnt = qs.count()
|
||||
if cnt == 0:
|
||||
raise AppError('USER_DEPARTMENT_NOT_FOUND', f'科室"{department_name}"不存在')
|
||||
|
||||
Reference in New Issue
Block a user