Browse Source

[Bugfix] IsSuperUserOrAppUser deny app user (#2558)

pull/2599/head
jokimina 6 years ago committed by 老广
parent
commit
78e4e13fb9
  1. 2
      apps/common/permissions.py

2
apps/common/permissions.py

@ -35,7 +35,7 @@ class IsSuperUser(IsValidUser):
class IsSuperUserOrAppUser(IsSuperUser):
def has_permission(self, request, view):
return super(IsSuperUserOrAppUser, self).has_permission(request, view) \
and (request.user.is_superuser or request.user.is_app)
or request.user.is_app
class IsOrgAdmin(IsValidUser):

Loading…
Cancel
Save