fix(api): common department edit method (#356)

* fix(api): common department edit method

* fix(api): common department edit method
This commit is contained in:
simontigers 2024-01-03 14:31:54 +08:00 committed by GitHub
parent 995e581315
commit 82ea1ddc79
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -62,7 +62,7 @@ class DepartmentView(APIView):
class DepartmentIDView(APIView):
url_prefix = (f'{prefix}/<int:_id>',)
def get(self, _id):
def put(self, _id):
form = DepartmentForm(MultiDict(request.json))
if not form.validate():
abort(400, ','.join(['{}: {}'.format(filed, ','.join(msg))