mirror of
https://github.com/ansible/awx.git
synced 2026-03-01 08:48:46 -03:30
get_one now also returns the name field, and modifying modules for get_one and added in some IDs in a handful of unit tests
This commit is contained in:
@@ -175,9 +175,8 @@ def main():
|
||||
{% endfor %}
|
||||
|
||||
# Attempt to look up an existing item based on the provided data
|
||||
existing_item = module.get_one('{{ item_type }}', **{
|
||||
existing_item, name = module.get_one('{{ item_type }}', name_or_id={{ name_option }}, **{
|
||||
'data': {
|
||||
'{{ name_option }}': {{ name_option }},
|
||||
{% if 'organization' in item['json']['actions']['POST'] and item['json']['actions']['POST']['organization']['type'] == 'id' %}
|
||||
'organization': org_id,
|
||||
{% endif %}
|
||||
|
||||
Reference in New Issue
Block a user