mirror of
https://github.com/ansible/awx.git
synced 2024-11-01 16:51:11 +03:00
Merge pull request #4017 from jangsutsr/3976_rename_type_in_wfjt_delete_conflict_message
Rename type in workflow job template delete conflict message
This commit is contained in:
commit
44cc57afba
@ -1554,7 +1554,7 @@ class WorkflowJobTemplateAccess(BaseAccess):
|
||||
is_delete_allowed = self.user.is_superuser or self.user in obj.admin_role
|
||||
if not is_delete_allowed:
|
||||
return False
|
||||
active_jobs = [dict(type="job", id=o.id)
|
||||
active_jobs = [dict(type="workflow_job", id=o.id)
|
||||
for o in obj.jobs.filter(status__in=ACTIVE_STATES)]
|
||||
if len(active_jobs) > 0:
|
||||
raise StateConflict({"conflict": _("Resource is being used by running jobs"),
|
||||
|
Loading…
Reference in New Issue
Block a user