AC-1118 added job_explanation to log viewer. Also, fixed issue where once 'standard out' or 'traceback' tabs were hidden, they would never reappear.

This commit is contained in:
Chris Houseknecht 2014-04-01 19:15:38 -04:00
parent 4d6ce4b5fa
commit fb5b069273
4 changed files with 22 additions and 16 deletions

1
.gitignore vendored
View File

@ -1,5 +1,6 @@
awx/settings/local_settings.py*
awx/*.sqlite3
awx/job_status
awx/projects
awx/job_output
awx/public/media

View File

@ -18,6 +18,16 @@ angular.module('LogViewerStatusDefinition', [])
type: "text",
readonly: true,
},
"status": {
label: "Status",
type: "text",
readonly: true
},
"license_error": {
label: "License Error",
type: "text",
readonly: true
},
"started": {
label: "Started",
type: "text",
@ -37,16 +47,6 @@ angular.module('LogViewerStatusDefinition', [])
label: "Launch Type",
type: "text",
readonly: true
},
"status": {
label: "Status",
type: "text",
readonly: true
},
"license_error": {
label: "License Error",
type: "text",
readonly: true
}
}

View File

@ -73,7 +73,6 @@ angular.module('JobsHelper', ['Utilities', 'RestServices', 'FormGenerator', 'Job
scope.viewJobLog = function(id, url) {
var list, job;
if (url) {
console.log(url);
$location.url(url);
}
else {

View File

@ -41,6 +41,7 @@ angular.module('LogViewerHelper', ['ModalDialog', 'Utilities', 'FormGenerator',
AddTable({ scope: scope, form: LogViewerOptionsForm, id: 'options-form-container', getIcon: getIcon });
if (data.result_stdout) {
$('#logview-tabs li:eq(1)').show();
AddPreFormattedText({
id: 'stdout-form-container',
val: data.result_stdout
@ -51,6 +52,7 @@ angular.module('LogViewerHelper', ['ModalDialog', 'Utilities', 'FormGenerator',
}
if (data.result_traceback) {
$('#logview-tabs li:eq(2)').show();
AddPreFormattedText({
id: 'traceback-form-container',
val: data.result_traceback
@ -236,12 +238,16 @@ angular.module('LogViewerHelper', ['ModalDialog', 'Utilities', 'FormGenerator',
else if (fld === 'elapsed') {
html += scope[fld] + " <span class=\"small-text\">seconds</span>";
}
else if (getIcon && fld === 'status') {
html += "<i class=\"fa icon-job-" + getIcon(scope[fld]) + "\"></i> " + scope[fld];
//html += "<i class=\"fa " + status_icon + scope[fld] + "\"></i> " + scope[fld];
}
else if (fld === 'status') {
html += "<i class=\"fa icon-job-" + scope[fld] + "\"></i> " + scope[fld];
if (getIcon) {
html += "<i class=\"fa icon-job-" + getIcon(scope[fld]) + "\"></i> " + scope[fld];
}
else {
html += "<i class=\"fa icon-job-" + scope[fld] + "\"></i> " + scope[fld];
}
if (scope.job_explanation) {
html += "<p style=\"padding-top: 12px\">" + scope.job_explanation + "</p>";
}
}
else {
html += scope[fld];