mirror of
https://github.com/ansible/awx.git
synced 2026-01-11 18:09:57 -03:30
Merge pull request #99 from joefiorini/inventory-remove-checkbox
Remove checkbox on inventory list for enabling/disabling
This commit is contained in:
commit
a687bb7cdc
@ -41,6 +41,7 @@ export default
|
||||
key: true,
|
||||
label: 'Name',
|
||||
columnClass: 'col-lg-4 col-md3 col-sm-3 col-xs-7 ellipsis',
|
||||
ngClass: "{ 'host-disabled-label': !host.enabled }",
|
||||
ngClick: "editHost(host.id)"
|
||||
},
|
||||
inventory_name: {
|
||||
@ -78,14 +79,6 @@ export default
|
||||
},
|
||||
|
||||
fieldActions: {
|
||||
enabled_flag: {
|
||||
//label: 'Enabled',
|
||||
iconClass: "{{ 'fa icon-enabled-' + host.enabled }}",
|
||||
dataPlacement: 'top',
|
||||
awToolTip: "{{ host.enabledToolTip }}",
|
||||
dataTipWatch: "host.enabledToolTip",
|
||||
ngClick: "toggleHostEnabled(host.id, host.has_inventory_sources)"
|
||||
},
|
||||
/*active_failures: {
|
||||
//label: 'Job Status',
|
||||
//ngHref: "\{\{'/#/hosts/' + host.id + '/job_host_summaries/?inventory=' + inventory_id \}\}",
|
||||
@ -113,4 +106,4 @@ export default
|
||||
}
|
||||
}
|
||||
|
||||
});
|
||||
});
|
||||
|
||||
@ -28,6 +28,7 @@ export default
|
||||
key: true,
|
||||
label: 'Hosts',
|
||||
ngClick: "editHost(host.id)",
|
||||
ngClass: "{ 'host-disabled-label': !host.enabled }",
|
||||
columnClass: 'col-lg-8 col-md-9 col-sm-9 col-xs-7',
|
||||
dataHostId: "{{ host.id }}",
|
||||
dataType: "host"
|
||||
@ -53,13 +54,6 @@ export default
|
||||
columnClass: 'col-lg-4 col-md-3 col-sm-3 col-xs-5 text-right',
|
||||
label: false,
|
||||
|
||||
enabled_flag: {
|
||||
iconClass: "{{ 'fa icon-enabled-' + host.enabled }}",
|
||||
dataPlacement: 'top',
|
||||
awToolTip: "{{ host.enabledToolTip }}",
|
||||
dataTipWatch: "host.enabledToolTip",
|
||||
ngClick: "toggleHostEnabled(host.id, host.has_inventory_sources)"
|
||||
},
|
||||
active_failures: {
|
||||
awPopOver: "{{ host.job_status_html }}",
|
||||
dataTitle: "{{ host.job_status_title }}",
|
||||
@ -111,4 +105,4 @@ export default
|
||||
}
|
||||
}
|
||||
|
||||
});
|
||||
});
|
||||
|
||||
@ -336,6 +336,7 @@ angular.module('GeneratorHelpers', [systemStatus.name])
|
||||
|
||||
html = "<td class=\"" + fld + "-column";
|
||||
html += (field.columnClass) ? " " + field.columnClass : "";
|
||||
html += (field.columnNgClass) ? "\" ng-class=\"" + field.columnNgClass : "";
|
||||
html += "\">\n";
|
||||
html += "<a ng-href=\"" + field.ngHref + "\" aw-tool-tip=\"" + field.awToolTip + "\"";
|
||||
html += (field.dataPlacement) ? " data-placement=\"" + field.dataPlacement + "\"" : "";
|
||||
@ -595,7 +596,7 @@ angular.module('GeneratorHelpers', [systemStatus.name])
|
||||
html += " " + field.columnClass;
|
||||
}
|
||||
html += "\" ";
|
||||
html += (field.ngClass) ? Attr(field, 'ngClass') : "";
|
||||
html += field.columnNgClass ? " ng-class=\"" + field.columnNgClass + "\"": "";
|
||||
html += (options.mode === 'lookup' || options.mode === 'select') ? " ng-click=\"toggle_" + list.iterator +
|
||||
"(" + list.iterator + ".id)\"" : "";
|
||||
html += (field.columnShow) ? Attr(field, 'columnShow') : "";
|
||||
|
||||
@ -547,6 +547,7 @@ angular.module('ListGenerator', ['GeneratorHelpers'])
|
||||
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 + "')\"" : "";
|
||||
|
||||
@ -62,6 +62,7 @@
|
||||
@import "jPushMenu.less";
|
||||
@import "survey-maker.less";
|
||||
@import "portal.less";
|
||||
@import "text-label.less";
|
||||
|
||||
/* Bootstrap fix that's causing a right margin to appear
|
||||
whenver a modal is opened */
|
||||
|
||||
22
awx/ui/static/less/text-label.less
Normal file
22
awx/ui/static/less/text-label.less
Normal file
@ -0,0 +1,22 @@
|
||||
.include-text-label(@background-color; @color; @content) {
|
||||
display: inline-block;
|
||||
content: @content;
|
||||
|
||||
border-radius: 3px;
|
||||
background-color: @background-color;
|
||||
color: @color;
|
||||
text-transform: uppercase;
|
||||
font-size: .7em;
|
||||
font-weight: bold;
|
||||
font-style: normal;
|
||||
margin-left: 0.5em;
|
||||
padding: 0.35em;
|
||||
padding-bottom: 0.2em;
|
||||
line-height: 1.1;
|
||||
}
|
||||
|
||||
.host-disabled-label {
|
||||
&:after {
|
||||
.include-text-label(#676767; white; "disabled");
|
||||
}
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user