mirror of
https://github.com/ansible/awx.git
synced 2026-05-11 19:37:38 -02:30
passwords in WFJT surveys working correctly
This commit is contained in:
@@ -1,3 +1,6 @@
|
|||||||
|
# Python
|
||||||
|
import json
|
||||||
|
|
||||||
# Django
|
# Django
|
||||||
from django.db import models
|
from django.db import models
|
||||||
from django.contrib.contenttypes.models import ContentType
|
from django.contrib.contenttypes.models import ContentType
|
||||||
|
|||||||
@@ -232,12 +232,15 @@ class WorkflowJobNode(WorkflowNodeBase):
|
|||||||
if aa_dict:
|
if aa_dict:
|
||||||
self.ancestor_artifacts = aa_dict
|
self.ancestor_artifacts = aa_dict
|
||||||
self.save(update_fields=['ancestor_artifacts'])
|
self.save(update_fields=['ancestor_artifacts'])
|
||||||
|
password_dict = {}
|
||||||
if '_ansible_no_log' in aa_dict:
|
if '_ansible_no_log' in aa_dict:
|
||||||
# TODO: merge Workflow Job survey passwords into this
|
|
||||||
password_dict = {}
|
|
||||||
for key in aa_dict:
|
for key in aa_dict:
|
||||||
if key != '_ansible_no_log':
|
if key != '_ansible_no_log':
|
||||||
password_dict[key] = REPLACE_STR
|
password_dict[key] = REPLACE_STR
|
||||||
|
workflow_job_survey_passwords = self.workflow_job.survey_passwords
|
||||||
|
if workflow_job_survey_passwords:
|
||||||
|
password_dict.update(workflow_job_survey_passwords)
|
||||||
|
if password_dict:
|
||||||
data['survey_passwords'] = password_dict
|
data['survey_passwords'] = password_dict
|
||||||
# process extra_vars
|
# process extra_vars
|
||||||
# TODO: still lack consensus about variable precedence
|
# TODO: still lack consensus about variable precedence
|
||||||
|
|||||||
Reference in New Issue
Block a user