mirror of
https://github.com/ansible/awx.git
synced 2026-02-02 01:58:09 -03:30
Add name field for ad hoc commands, get relaunch working.
This commit is contained in:
@@ -1483,12 +1483,14 @@ class JobCancelSerializer(JobSerializer):
|
||||
|
||||
class AdHocCommandSerializer(UnifiedJobSerializer):
|
||||
|
||||
name = serializers.CharField(source='name', read_only=True)
|
||||
|
||||
class Meta:
|
||||
model = AdHocCommand
|
||||
fields = ('*', 'job_type', 'inventory', 'limit', 'credential',
|
||||
'module_name', 'module_args', 'forks', 'verbosity',
|
||||
'privilege_escalation')
|
||||
exclude = ('unified_job_template', 'name', 'description')
|
||||
exclude = ('unified_job_template', 'description')
|
||||
|
||||
def get_related(self, obj):
|
||||
res = super(AdHocCommandSerializer, self).get_related(obj)
|
||||
|
||||
Reference in New Issue
Block a user