mirror of
https://github.com/ansible/awx.git
synced 2024-11-02 09:51:09 +03:00
hide launch button for invalid JTs
This commit is contained in:
parent
afd54a9ff9
commit
d8f37e799b
@ -344,7 +344,7 @@ class BaseAccess(object):
|
||||
if 'write' not in getattr(self.user, 'oauth_scopes', ['write']):
|
||||
user_capabilities[display_method] = False # Read tokens cannot take any actions
|
||||
continue
|
||||
elif display_method == 'copy' and isinstance(obj, JobTemplate):
|
||||
elif display_method in ['copy', 'start', 'schedule'] and isinstance(obj, JobTemplate):
|
||||
if obj.validation_errors:
|
||||
user_capabilities[display_method] = False
|
||||
continue
|
||||
|
Loading…
Reference in New Issue
Block a user