mirror of
https://github.com/ansible/awx.git
synced 2026-03-01 00:38:45 -03:30
Allow SA's to read all notification templates
This commit is contained in:
@@ -1375,6 +1375,8 @@ class NotificationTemplateAccess(BaseAccess):
|
|||||||
|
|
||||||
@check_superuser
|
@check_superuser
|
||||||
def can_read(self, obj):
|
def can_read(self, obj):
|
||||||
|
if self.user.is_superuser or self.user.is_system_auditor:
|
||||||
|
return True
|
||||||
if obj.organization is not None:
|
if obj.organization is not None:
|
||||||
return self.user in obj.organization.admin_role
|
return self.user in obj.organization.admin_role
|
||||||
return False
|
return False
|
||||||
|
|||||||
Reference in New Issue
Block a user