fix: 修复用户API权限

pull/7947/head
Jiangjie.Bai 3 years ago committed by Jiangjie.Bai
parent 9e5c132485
commit 9ae74120ed

@ -109,7 +109,7 @@ class UserViewSet(CommonApiMixin, UserQuerysetMixin, SuggestionMixin, BulkModelV
return super().perform_bulk_update(serializer) return super().perform_bulk_update(serializer)
def allow_bulk_destroy(self, qs, filtered): def allow_bulk_destroy(self, qs, filtered):
return qs.count() != filtered.count() return filtered.count() < qs.count()
def perform_bulk_destroy(self, objects): def perform_bulk_destroy(self, objects):
for obj in objects: for obj in objects:

Loading…
Cancel
Save