Rename job_summary_dict to job_metadata

* Clarifies purpose of notification template variable
This commit is contained in:
Jim Ladd
2019-10-23 12:41:17 -07:00
committed by Ryan Petrello
parent acba5306c6
commit 71d7bac261
7 changed files with 8 additions and 8 deletions

View File

@@ -4,7 +4,7 @@
class CustomNotificationBase(object):
DEFAULT_MSG = "{{ job_friendly_name }} #{{ job.id }} '{{ job.name }}' {{ job.status }}: {{ url }}"
DEFAULT_BODY = "{{ job_friendly_name }} #{{ job.id }} had status {{ job.status }}, view details at {{ url }}\n\n{{ job_summary_dict }}"
DEFAULT_BODY = "{{ job_friendly_name }} #{{ job.id }} had status {{ job.status }}, view details at {{ url }}\n\n{{ job_metadata }}"
default_messages = {"started": {"message": DEFAULT_MSG, "body": None},
"success": {"message": DEFAULT_MSG, "body": None},

View File

@@ -26,7 +26,7 @@ class PagerDutyBackend(AWXBaseEmailBackend, CustomNotificationBase):
recipient_parameter = "service_key"
sender_parameter = "client_name"
DEFAULT_BODY = "{{ job_summary_dict }}"
DEFAULT_BODY = "{{ job_metadata }}"
default_messages = {"started": {"message": DEFAULT_MSG, "body": DEFAULT_BODY},
"success": {"message": DEFAULT_MSG, "body": DEFAULT_BODY},
"error": {"message": DEFAULT_MSG, "body": DEFAULT_BODY},

View File

@@ -26,7 +26,7 @@ class WebhookBackend(AWXBaseEmailBackend, CustomNotificationBase):
recipient_parameter = "url"
sender_parameter = None
DEFAULT_BODY = "{{ job_summary_dict }}"
DEFAULT_BODY = "{{ job_metadata }}"
default_messages = {"started": {"body": DEFAULT_BODY},
"success": {"body": DEFAULT_BODY},
"error": {"body": DEFAULT_BODY},