mirror of
https://github.com/ZwareBear/awx.git
synced 2026-04-28 02:41:49 -05:00
Fix an issue where extra data wasn't being passed down to system jobs
from the schedules
This commit is contained in:
@@ -1003,6 +1003,24 @@ class SystemJob(UnifiedJob, SystemJobOptions):
|
||||
def is_blocked_by(self, obj):
|
||||
return True
|
||||
|
||||
|
||||
def handle_extra_data(self, extra_data):
|
||||
extra_vars = {}
|
||||
if type(extra_data) == dict:
|
||||
extra_vars = extra_data
|
||||
elif extra_data is None:
|
||||
return
|
||||
else:
|
||||
if extra_data == "":
|
||||
return
|
||||
try:
|
||||
extra_vars = json.loads(extra_data)
|
||||
except Exception, e:
|
||||
logger.warn("Exception deserializing extra vars: " + str(e))
|
||||
evars = self.extra_vars_dict
|
||||
evars.update(extra_vars)
|
||||
self.update_fields(extra_vars=json.dumps(evars))
|
||||
|
||||
@property
|
||||
def task_impact(self):
|
||||
return 150
|
||||
|
||||
Reference in New Issue
Block a user