mirror of
https://github.com/ansible/awx.git
synced 2026-03-03 17:51:06 -03:30
@@ -3666,7 +3666,7 @@ class AdHocCommandRelaunch(GenericAPIView):
|
||||
data = {}
|
||||
for field in ('job_type', 'inventory_id', 'limit', 'credential_id',
|
||||
'module_name', 'module_args', 'forks', 'verbosity',
|
||||
'become_enabled'):
|
||||
'extra_vars', 'become_enabled'):
|
||||
if field.endswith('_id'):
|
||||
data[field[:-3]] = getattr(obj, field)
|
||||
else:
|
||||
|
||||
@@ -190,7 +190,7 @@ class AdHocCommand(UnifiedJob, JobNotificationMixin):
|
||||
data = {}
|
||||
for field in ('job_type', 'inventory_id', 'limit', 'credential_id',
|
||||
'module_name', 'module_args', 'forks', 'verbosity',
|
||||
'become_enabled'):
|
||||
'extra_vars', 'become_enabled'):
|
||||
data[field] = getattr(self, field)
|
||||
return AdHocCommand.objects.create(**data)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user