check permission with PermissionBackend.
taking connection permission mask into account.
This commit is contained in:
parent
33139bdbde
commit
d4b8d35206
2 changed files with 3 additions and 2 deletions
|
|
@ -89,6 +89,7 @@ class PermissionBackend(ModelBackend):
|
|||
query = query | perm.query
|
||||
return query
|
||||
|
||||
@staticmethod
|
||||
def has_perm(self, user_obj, perm, obj=None):
|
||||
if user_obj is None or isinstance(user_obj, AnonymousUser):
|
||||
return False
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue