mirror of
https://github.com/ansible/awx.git
synced 2024-11-01 16:51:11 +03:00
AC-1294 stdout button is now available at all times regardless of job status. AC-1272 lookup dialog clean up. Previous list clean up assigned column width classes to most columns. These classes were being used to build lookup dialogs. The list generator now checks if for 'lookup' mode and a modalColumnClass setting rather than blindly using columnClass.
This commit is contained in:
parent
c9bb424d98
commit
2b4014cf4d
@ -26,7 +26,8 @@ angular.module('CredentialsListDefinition', [])
|
||||
name: {
|
||||
key: true,
|
||||
label: 'Name',
|
||||
columnClass: 'col-md-3 col-sm-9 col-xs-9'
|
||||
columnClass: 'col-md-3 col-sm-9 col-xs-9',
|
||||
modalColumnClass: 'col-md-8'
|
||||
},
|
||||
description: {
|
||||
label: 'Description',
|
||||
|
@ -28,6 +28,7 @@ angular.module('InventoriesListDefinition', [])
|
||||
nosort: true,
|
||||
ngClick: "null",
|
||||
iconOnly: true,
|
||||
excludeModal: true,
|
||||
icons: [{
|
||||
icon: "{{ 'icon-cloud-' + inventory.syncStatus }}",
|
||||
awToolTip: "{{ inventory.syncTip }}",
|
||||
@ -45,7 +46,8 @@ angular.module('InventoriesListDefinition', [])
|
||||
name: {
|
||||
key: true,
|
||||
label: 'Name',
|
||||
columnClass: 'col-md-4 col-sm-6 col-xs-6'
|
||||
columnClass: 'col-md-4 col-sm-6 col-xs-6',
|
||||
modalColumnClass: 'col-md-8'
|
||||
},
|
||||
organization: {
|
||||
label: 'Organization',
|
||||
|
@ -27,7 +27,8 @@ angular.module('OrganizationListDefinition', [])
|
||||
},
|
||||
description: {
|
||||
label: 'Description',
|
||||
columnClass: 'hidden-sm hidden-xs'
|
||||
columnClass: 'hidden-sm hidden-xs',
|
||||
excludeModal: true
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -33,12 +33,14 @@ angular.module('ProjectsListDefinition', [])
|
||||
columnClass: "col-lg-1 col-md-1 col-sm-2 col-xs-2",
|
||||
nosort: true,
|
||||
searchType: 'select',
|
||||
searchOptions: [] //set in the controller
|
||||
searchOptions: [], //set in the controller
|
||||
excludeModal: true
|
||||
},
|
||||
name: {
|
||||
key: true,
|
||||
label: 'Name',
|
||||
columnClass: "col-lg-6 col-md-4 col-sm-6 col-xs-6"
|
||||
columnClass: "col-lg-6 col-md-4 col-sm-6 col-xs-6",
|
||||
modalColumnClass: 'col-md-8'
|
||||
},
|
||||
last_updated: {
|
||||
label: 'Last Updated',
|
||||
|
@ -24,18 +24,21 @@ angular.module('TeamsListDefinition', [])
|
||||
name: {
|
||||
key: true,
|
||||
label: 'Name',
|
||||
columnClass: 'col-md-4 col-sm-9 col-xs-9'
|
||||
columnClass: 'col-md-4 col-sm-9 col-xs-9',
|
||||
modalColumnClass: 'col-md-8'
|
||||
},
|
||||
description: {
|
||||
label: 'Description',
|
||||
columnClass: 'col-md-3 hidden-sm hidden-xs'
|
||||
columnClass: 'col-md-3 hidden-sm hidden-xs',
|
||||
excludeModal: true
|
||||
},
|
||||
organization: {
|
||||
label: 'Organization',
|
||||
ngBind: 'team.organization_name',
|
||||
sourceModel: 'organization',
|
||||
sourceField: 'name',
|
||||
columnClass: 'col-md-3 hidden-sm hidden-xs'
|
||||
columnClass: 'col-md-3 hidden-sm hidden-xs',
|
||||
excludeModal: true
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -80,7 +80,7 @@ angular.module('GeneratorHelpers', [])
|
||||
.factory('SelectIcon', ['Icon',
|
||||
function (Icon) {
|
||||
return function (params) {
|
||||
// Common point for matching any type of action to the appropriate
|
||||
// Common point for matching any type of action to the appropriate
|
||||
// icon. The intention is to maintain consistent meaning and presentation
|
||||
// for every icon used in the application.
|
||||
var icon,
|
||||
@ -465,7 +465,7 @@ angular.module('GeneratorHelpers', [])
|
||||
list = params.list,
|
||||
base = params.base,
|
||||
fld = params.fld;
|
||||
|
||||
|
||||
if (field.linkTo) {
|
||||
html += "<a href=\"" + field.linkTo + "\" ";
|
||||
} else if (field.ngClick) {
|
||||
@ -509,7 +509,7 @@ angular.module('GeneratorHelpers', [])
|
||||
html += Icon(field.icon) + " ";
|
||||
}
|
||||
|
||||
// Add data binds
|
||||
// Add data binds
|
||||
if (!field.ngBindHtml && !field.iconOnly && (field.showValue === undefined || field.showValue === true)) {
|
||||
if (field.ngBind) {
|
||||
html += "{{ " + field.ngBind;
|
||||
@ -552,7 +552,12 @@ angular.module('GeneratorHelpers', [])
|
||||
} else {
|
||||
html += "<td class=\"" + fld + "-column";
|
||||
html += (field['class']) ? " " + field['class'] : "";
|
||||
html += (field.columnClass) ? " " + field.columnClass : "";
|
||||
if (options.mode === 'lookup' && field.modalColumnClass) {
|
||||
html += " " + field.modalColumnClass;
|
||||
}
|
||||
else if (field.columnClass) {
|
||||
html += " " + field.columnClass;
|
||||
}
|
||||
html += "\" ";
|
||||
html += (field.ngClass) ? Attr(field, 'ngClass') : "";
|
||||
html += (options.mode === 'lookup' || options.mode === 'select') ? " ng-click=\"toggle_" + list.iterator +
|
||||
@ -617,7 +622,7 @@ angular.module('GeneratorHelpers', [])
|
||||
} else if (field.icon) {
|
||||
html += Icon(field.icon) + " ";
|
||||
}
|
||||
// Add data binds
|
||||
// Add data binds
|
||||
if (!field.ngBindHtml && !field.iconOnly && (field.showValue === undefined || field.showValue === true)) {
|
||||
if (field.ngBind) {
|
||||
html += "{{ " + field.ngBind;
|
||||
@ -662,14 +667,14 @@ angular.module('GeneratorHelpers', [])
|
||||
|
||||
.factory('HelpCollapse', function () {
|
||||
return function (params) {
|
||||
|
||||
|
||||
var hdr = params.hdr,
|
||||
content = params.content,
|
||||
show = params.show,
|
||||
idx = params.idx,
|
||||
bind = params.bind,
|
||||
html = '';
|
||||
|
||||
|
||||
html += "<div class=\"panel-group collapsible-help\" ";
|
||||
html += (show) ? "ng-show=\"" + show + "\"" : "";
|
||||
html += ">\n";
|
||||
@ -707,7 +712,7 @@ angular.module('GeneratorHelpers', [])
|
||||
modifier,
|
||||
searchWidgets = (params.searchWidgets) ? params.searchWidgets : 1,
|
||||
sortedKeys;
|
||||
|
||||
|
||||
function addSearchFields(idx) {
|
||||
var html = '';
|
||||
sortedKeys = Object.keys(form.fields).sort();
|
||||
@ -731,7 +736,7 @@ angular.module('GeneratorHelpers', [])
|
||||
|
||||
for (i = 1; i <= searchWidgets; i++) {
|
||||
modifier = (i === 1) ? '' : i;
|
||||
|
||||
|
||||
if (includeSize) {
|
||||
html += "<div class=\"";
|
||||
html += (size) ? size : "col-lg-4 col-md-6";
|
||||
@ -785,7 +790,7 @@ angular.module('GeneratorHelpers', [])
|
||||
"!" + iterator + "ShowStartBtn" + modifier + " || " +
|
||||
iterator + "HideAllStartBtn" + modifier + "\"" +
|
||||
"><i class=\"fa fa-search\"></i></a>\n";
|
||||
|
||||
|
||||
if (includeSize) {
|
||||
html += "</div>\n";
|
||||
}
|
||||
|
@ -323,8 +323,7 @@ angular.module('ListGenerator', ['GeneratorHelpers'])
|
||||
for (fld in list.fields) {
|
||||
cnt++;
|
||||
if ((list.fields[fld].searchOnly === undefined || list.fields[fld].searchOnly === false) &&
|
||||
!(options.mode === 'lookup' && list.fields[fld].excludeModal !== undefined &&
|
||||
list.fields[fld].excludeModal === true)) {
|
||||
!(options.mode === 'lookup' && list.fields[fld].excludeModal === true)) {
|
||||
html += Column({
|
||||
list: list,
|
||||
fld: fld,
|
||||
@ -449,9 +448,14 @@ angular.module('ListGenerator', ['GeneratorHelpers'])
|
||||
}
|
||||
for (fld in list.fields) {
|
||||
if ((list.fields[fld].searchOnly === undefined || list.fields[fld].searchOnly === false) &&
|
||||
!(options.mode === 'lookup' && list.fields[fld].excludeModal !== undefined && list.fields[fld].excludeModal === true)) {
|
||||
!(options.mode === 'lookup' && list.fields[fld].excludeModal === true)) {
|
||||
html += "<th class=\"list-header";
|
||||
html += (list.fields[fld].columnClass) ? " " + list.fields[fld].columnClass : "";
|
||||
if (options.mode === 'lookup' && list.fields[fld].modalColumnClass) {
|
||||
html += " " + list.fields[fld].modalColumnClass;
|
||||
}
|
||||
else if (list.fields[fld].columnClass) {
|
||||
html += " " + list.fields[fld].columnClass;
|
||||
}
|
||||
html += "\" id=\"" + list.iterator + "-" + fld + "-header\"";
|
||||
html += (list.fields[fld].columnShow) ? " ng-show=\"" + list.fields[fld].columnShow + "\" " : "";
|
||||
html += (list.fields[fld].nosort === undefined || list.fields[fld].nosort !== true) ? " ng-click=\"sort('" + list.iterator + "','" + fld + "')\"" : "";
|
||||
|
@ -1,6 +1,6 @@
|
||||
<div class="tab-pane" id="jobs-detail">
|
||||
<div ng-cloak id="htmlTemplate">
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div id="breadcrumb-container" class="col-md-12" style="position: relative;">
|
||||
<div class="nav-path">
|
||||
@ -11,7 +11,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row" style="position: relative;">
|
||||
<div id="job-detail-container">
|
||||
<div class="job_well">
|
||||
@ -20,7 +20,7 @@
|
||||
<div class="col-lg-2 col-md-2 col-sm-4 col-xs-4 status-column"><i class="fa icon-job-{{ job_status.status }}"></i> {{ job_status.status }}</div>
|
||||
<div class="col-lg-7 col-md-7 col-sm-4 col-xs-4">{{ job_status.explanation }}</div>
|
||||
<div class="col-lg-2 col-md-2 col-sm-2 col-xs-2 text-right">
|
||||
<a href="/#/jobs/{{ job_id }}/stdout" target="_blank" type="button" class="btn btn-default btn-xs" aw-tool-tip="View standard out. Opens in new tab or window." data-placement="top" ng-show="job_status.status == 'successful' || job_status.status == 'failed' || job_status.status == 'error'"><i class="fa fa-external-link"></i></a>
|
||||
<a href="/#/jobs/{{ job_id }}/stdout" target="_blank" type="button" class="btn btn-default btn-xs" aw-tool-tip="View standard out. Opens in new tab or window." data-placement="top"><i class="fa fa-external-link"></i></a>
|
||||
<button type="button" id="summary-button" class="btn btn-default btn-xs" ng-click="toggleSummary()" aw-tool-tip="View summary" data-placement="top"><i class="fa fa-arrow-circle-left fa-lg"></i></button>
|
||||
</div>
|
||||
</div>
|
||||
@ -52,14 +52,14 @@
|
||||
</div>
|
||||
</div>
|
||||
<div id="plays-table-detail" aw-custom-scroll class="table-detail">
|
||||
<div class="row cursor-pointer"
|
||||
ng-repeat="play in plays | FilterById : search_all_plays | filter:{ status : searchAllStatus}"
|
||||
<div class="row cursor-pointer"
|
||||
ng-repeat="play in plays | FilterById : search_all_plays | filter:{ status : searchAllStatus}"
|
||||
ng-class="play.playActiveClass" ng-click="selectPlay(play.id)">
|
||||
<div class="col-lg-1 col-md-1 col-sm-2 hidden-xs">{{ play.created | date: 'HH:mm:ss' }}</div>
|
||||
<div class="col-lg-1 col-md-1 hidden-sm hidden-xs" aw-tool-tip="Completed at {{ play.finished | date:'HH:mm:ss' }}"
|
||||
data-placement="top">{{ play.elapsed }}
|
||||
</div>
|
||||
<div class="col-lg-10 col-md-10 col-sm-10 col-xs-12 status-column" aw-tool-tip="Event Id: {{ play.id }}<br />Status: {{ play.status_text }}"
|
||||
<div class="col-lg-10 col-md-10 col-sm-10 col-xs-12 status-column" aw-tool-tip="Event Id: {{ play.id }}<br />Status: {{ play.status_text }}"
|
||||
data-placement="top">
|
||||
<i class="fa icon-job-{{ play.status }}"></i> {{ play.name }}</span>
|
||||
</div>
|
||||
@ -84,7 +84,7 @@
|
||||
<div class="col-lg-1 col-md-1 hidden-sm hidden-xs" aw-tool-tip="Completed at {{ task.finished | date:'HH:mm:ss' }}"
|
||||
data-placement="top">{{ task.elapsed }}
|
||||
</div>
|
||||
<div class="col-lg-5 col-md-5 col-sm-10 col-xs-12 status-column" aw-tool-tip="Event Id: {{ task.id }} Status: {{ task.status }}"
|
||||
<div class="col-lg-5 col-md-5 col-sm-10 col-xs-12 status-column" aw-tool-tip="Event Id: {{ task.id }} Status: {{ task.status }}"
|
||||
data-placement="top">
|
||||
<i class="fa icon-job-{{ task.status }}"></i><span ng-show="hasRoles"> {{ task.role }} </span> {{ task.name }}
|
||||
</div>
|
||||
@ -130,7 +130,7 @@
|
||||
</div><!-- section -->
|
||||
|
||||
</div><!-- job-detail-tables -->
|
||||
|
||||
|
||||
</div><!-- well -->
|
||||
|
||||
</div><!-- job-detail-container -->
|
||||
@ -171,7 +171,7 @@
|
||||
<div id="hosts-summary-section" class="section job_summary">
|
||||
<div class="header">
|
||||
<div class="title">Host Summary</div>
|
||||
<div class="legend pull-right"><i class="fa fa-circle successful-hosts-color"></i> Successful <i class="fa fa-circle changed-hosts-color"></i> Changed
|
||||
<div class="legend pull-right"><i class="fa fa-circle successful-hosts-color"></i> Successful <i class="fa fa-circle changed-hosts-color"></i> Changed
|
||||
<i class="fa fa-circle unreachable-hosts-color"></i> Unreachable <i class="fa fa-circle failed-hosts-color"></i> Failed</div>
|
||||
</div>
|
||||
<div class="table-header">
|
||||
@ -206,10 +206,10 @@
|
||||
<div id="graph-section" class="section">
|
||||
<div class="header">
|
||||
<div class="title">Host Status Summary</div>
|
||||
<div class="legend pull-right" style="display: none;"><i class="fa fa-circle successful-hosts-color"></i> Successful <i class="fa fa-circle changed-hosts-color"></i> Changed
|
||||
<div class="legend pull-right" style="display: none;"><i class="fa fa-circle successful-hosts-color"></i> Successful <i class="fa fa-circle changed-hosts-color"></i> Changed
|
||||
<i class="fa fa-circle unreachable-hosts-color"></i> Unreachable <i class="fa fa-circle failed-hosts-color"></i> Failed</div>
|
||||
</div>
|
||||
</div><!-- graph section -->
|
||||
</div><!-- graph section -->
|
||||
</div>
|
||||
</div><!-- col-md-5 -->
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user