From 7a093de9fde31ec11c831979cf1827eb7958368a Mon Sep 17 00:00:00 2001 From: Jake McDermott Date: Wed, 27 Mar 2019 08:11:58 -0400 Subject: [PATCH] add workaround for null cloud credential kind summary fields job details summary field credentials have `null` for the `kind` field so we can't map it to icon names. To work around this, we now check the value of the `cloud` field when generating the icon to use. --- awx/ui/client/features/output/details.component.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/awx/ui/client/features/output/details.component.js b/awx/ui/client/features/output/details.component.js index 67f3bee4a0..a2519ef002 100644 --- a/awx/ui/client/features/output/details.component.js +++ b/awx/ui/client/features/output/details.component.js @@ -465,7 +465,13 @@ function getCredentialDetails () { } function buildCredentialDetails (credential) { - const icon = `${credential.kind}`; + let icon; + if (credential.cloud) { + icon = 'cloud'; + } else { + icon = `${credential.kind}`; + } + const link = `/#/credentials/${credential.id}`; const tooltip = strings.get('tooltips.CREDENTIAL'); const value = $filter('sanitize')(credential.name);