fix(api): common department allow parent (#358)

* fix(api): common department edit method

* fix(api): common department edit method

* fix(api): common department allow parent
This commit is contained in:
simontigers 2024-01-03 15:19:08 +08:00 committed by GitHub
parent c98199e98e
commit 4261f6fb57
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -85,7 +85,7 @@ class DepartmentIDView(APIView):
class DepartmentParentView(APIView): class DepartmentParentView(APIView):
url_prefix = (f'{prefix}/allow_parent',) url_prefix = (f'{prefix}/allow_parent',)
def put(self): def get(self):
department_id = request.args.get('department_id', None) department_id = request.args.get('department_id', None)
if department_id is None: if department_id is None:
abort(400, ErrFormat.department_id_is_required) abort(400, ErrFormat.department_id_is_required)