diff --git a/awx/ui/static/js/helpers/EventViewer.js b/awx/ui/static/js/helpers/EventViewer.js
index 41f3a14007..8d4f82f3d6 100644
--- a/awx/ui/static/js/helpers/EventViewer.js
+++ b/awx/ui/static/js/helpers/EventViewer.js
@@ -209,51 +209,51 @@ angular.module('EventViewerHelper', ['ModalDialog', 'Utilities', 'EventsViewerFo
keys.forEach(function(key) {
var label;
//if (EventsViewerForm.fields[key] && EventsViewerForm.fields[key].section === section) {
- label = EventsViewerForm.fields[key].label;
- if (Empty(obj[key])) {
- // exclude empty items
+ label = EventsViewerForm.fields[key].label;
+ if (Empty(obj[key])) {
+ // exclude empty items
+ }
+ else if (typeof obj[key] === "boolean" || typeof obj[key] === "number" || typeof obj[key] === "string") {
+ found = true;
+ html += "
| " + label + ": | ";
+ if (key === "status") {
+ html += " " + obj[key];
}
- else if (typeof obj[key] === "boolean" || typeof obj[key] === "number" || typeof obj[key] === "string") {
- found = true;
- html += " |
| " + label + ": | ";
- if (key === "status") {
- html += " " + obj[key];
- }
- else if (key === "start" || key === "end" || key === "created") {
- if (!/Z$/.test(obj[key])) {
- //sec = parseInt(obj[key].substr(obj[key].length - 6, 6),10) / 1000);
- //obj[key] = obj[key].replace(/\d{6}$/,sec) + 'Z';
- obj[key] = obj[key].replace(/\ /,'T') + 'Z';
- html += $filter('date')(obj[key], 'MM/dd/yy HH:mm:ss.sss');
- }
- else {
- html += $filter('date')(obj[key], 'MM/dd/yy HH:mm:ss');
- }
- }
- else if (key === "host_name" && obj.host_id) {
- html += "" + obj[key] + "";
+ else if (key === "start" || key === "end" || key === "created") {
+ if (!/Z$/.test(obj[key])) {
+ //sec = parseInt(obj[key].substr(obj[key].length - 6, 6),10) / 1000);
+ //obj[key] = obj[key].replace(/\d{6}$/,sec) + 'Z';
+ obj[key] = obj[key].replace(/\ /,'T') + 'Z';
+ html += $filter('date')(obj[key], 'MM/dd/yy HH:mm:ss.sss');
}
else {
- html += obj[key];
+ html += $filter('date')(obj[key], 'MM/dd/yy HH:mm:ss');
}
+ }
+ else if (key === "host_name" && obj.host_id) {
+ html += "" + obj[key] + "";
+ }
+ else {
+ html += obj[key];
+ }
- html += " |
\n";
- }
- else if (typeof obj[key] === "object" && Array.isArray(obj[key])) {
- found = true;
- html += "| " + label + ": | ";
- obj[key].forEach(function(row) {
- html += "[" + row + "],";
- });
- html = html.replace(/,$/,'');
- html += " |
\n";
- }
- else if (typeof obj[key] === "object") {
- found = true;
- html += "| " + label + ": | \n" + parseJSON(obj[key]) + " |
\n";
- }
+ html += "\n";
+ }
+ else if (typeof obj[key] === "object" && Array.isArray(obj[key])) {
+ found = true;
+ html += "| " + label + ": | ";
+ obj[key].forEach(function(row) {
+ html += "[" + row + "],";
+ });
+ html = html.replace(/,$/,'');
+ html += " |
\n";
+ }
+ else if (typeof obj[key] === "object") {
+ found = true;
+ html += "| " + label + ": | \n" + parseJSON(obj[key]) + " |
\n";
+ }
//}
});
html += "\n";
@@ -293,4 +293,4 @@ angular.module('EventViewerHelper', ['ModalDialog', 'Utilities', 'EventsViewerFo
html = "" + val + "
\n";
$('#' + id).empty().html(html);
};
- }]);
\ No newline at end of file
+ }]);