mirror of
https://github.com/ansible/awx.git
synced 2026-01-15 11:50:42 -03:30
AC-1325 plus inventory refactor cleanup
Fixed obvious issues found after pulling in inventory refactor changes from 1.4.11 branch. Included fixing modal dialog issues.
This commit is contained in:
parent
0cfef78663
commit
ad5d0454c2
@ -486,7 +486,7 @@ InventoriesAdd.$inject = ['$scope', '$rootScope', '$compile', '$location', '$log
|
||||
function InventoriesEdit ($scope, $location, $routeParams, $compile, GenerateList, ClearScope, Empty, Wait, Rest, Alert, LoadBreadCrumbs, GetBasePath, ProcessErrors,
|
||||
Breadcrumbs, InventoryGroups, InjectHosts, Find, HostsReload, SearchInit, PaginateInit, GetSyncStatusMsg, GetHostsStatusMsg, GroupsEdit, InventoryUpdate,
|
||||
GroupsCancelUpdate, ViewUpdateStatus, GroupsDelete, Store, HostsEdit, HostsDelete, EditInventoryProperties, ToggleHostEnabled, Stream, ShowJobSummary,
|
||||
InventoryGroupsHelp, HelpDialog, ViewJob, WatchInventoryWindowResize, SetContainerHeights, GetHostContainerRows, GetGroupContainerRows, GetGroupContainerHeight,
|
||||
InventoryGroupsHelp, HelpDialog, ViewJob, WatchInventoryWindowResize, GetHostContainerRows, GetGroupContainerRows, GetGroupContainerHeight,
|
||||
GroupsCopy, HostsCopy)
|
||||
{
|
||||
|
||||
@ -519,7 +519,19 @@ function InventoriesEdit ($scope, $location, $routeParams, $compile, GenerateLis
|
||||
}
|
||||
$scope.removeHostReloadComplete = $scope.$on('HostReloadComplete', function() {
|
||||
if ($scope.initial_height) {
|
||||
$('#hosts-container .well').height($scope.initial_height + 49);
|
||||
var host_height = $('#hosts-container .well').height(),
|
||||
group_height = $('#group-list-container .well').height(),
|
||||
new_height;
|
||||
|
||||
if (host_height > group_height) {
|
||||
new_height = host_height - (host_height - group_height);
|
||||
}
|
||||
else if (host_height < group_height) {
|
||||
new_height = host_height + (group_height - host_height);
|
||||
}
|
||||
if (new_height) {
|
||||
$('#hosts-container .well').height(new_height);
|
||||
}
|
||||
$scope.initial_height = null;
|
||||
}
|
||||
});
|
||||
@ -549,17 +561,10 @@ function InventoriesEdit ($scope, $location, $routeParams, $compile, GenerateLis
|
||||
scope: $scope
|
||||
});
|
||||
|
||||
/*SetContainerHeights({
|
||||
group_scope: $scope,
|
||||
host_scope: hostScope,
|
||||
reloadHosts: false
|
||||
});*/
|
||||
|
||||
if ($(window).width() > 1210) {
|
||||
$scope.initial_height = GetGroupContainerHeight() - 20;
|
||||
$scope.initial_height = GetGroupContainerHeight();
|
||||
$('#groups-container .list-table-container').height($scope.initial_height);
|
||||
rows = GetGroupContainerRows();
|
||||
//$('#hosts-container .well').height( height );
|
||||
}
|
||||
else {
|
||||
rows = 20;
|
||||
|
||||
@ -10,7 +10,7 @@ angular.module('InventoryFormDefinition', [])
|
||||
.value('InventoryForm', {
|
||||
|
||||
addTitle: 'Create Inventory',
|
||||
editTitle: '{{ inventory_name | capitalize }}',
|
||||
editTitle: '{{ inventory_name }}',
|
||||
name: 'inventory',
|
||||
well: true,
|
||||
|
||||
|
||||
@ -9,7 +9,7 @@ angular.module('InventoryGroupsDefinition', [])
|
||||
|
||||
name: 'groups',
|
||||
iterator: 'group',
|
||||
editTitle: '{{ inventory_name }}',
|
||||
editTitle: '{{ inventory.name }}',
|
||||
showTitle: false,
|
||||
well: true,
|
||||
index: false,
|
||||
@ -134,7 +134,7 @@ angular.module('InventoryGroupsDefinition', [])
|
||||
edit: {
|
||||
//label: 'Edit',
|
||||
mode: 'all',
|
||||
ngClick: "editGroup(group.group_id, group.id)",
|
||||
ngClick: "editGroup(group.id)",
|
||||
awToolTip: 'Edit group',
|
||||
dataPlacement: "top"
|
||||
},
|
||||
@ -148,7 +148,7 @@ angular.module('InventoryGroupsDefinition', [])
|
||||
"delete": {
|
||||
//label: 'Delete',
|
||||
mode: 'all',
|
||||
ngClick: "deleteGroup(group.id, group.group_id)",
|
||||
ngClick: "deleteGroup(group.id)",
|
||||
awToolTip: 'Delete group',
|
||||
dataPlacement: "top"
|
||||
}
|
||||
|
||||
@ -1330,29 +1330,6 @@ input[type="checkbox"].checkbox-no-label {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
#groups-table-header {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
#groups-container {
|
||||
.list-table-container {
|
||||
overflow: auto;
|
||||
}
|
||||
.list-actions {
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
}
|
||||
|
||||
#hosts-container {
|
||||
.list-table-container {
|
||||
position: relative;
|
||||
top: -15px;
|
||||
}
|
||||
.well {
|
||||
margin-bottom: 8px;
|
||||
}
|
||||
}
|
||||
|
||||
#inventories_table i[class*="icon-job-"],
|
||||
#home_groups_table i[class*="icon-job-"] {
|
||||
margin-left: 10px;
|
||||
|
||||
@ -116,8 +116,9 @@
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
|
||||
#group-list-container {
|
||||
.list-actions {
|
||||
margin-bottom: 0;
|
||||
#group-list-container,
|
||||
#hosts-container {
|
||||
.page-row {
|
||||
margin-top: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
@ -1136,7 +1136,7 @@ angular.module('FormGenerator', ['GeneratorHelpers', 'Utilities', 'ListGenerator
|
||||
}
|
||||
}
|
||||
|
||||
if (!this.modal && this.form.actions) {
|
||||
if ((options.showActions === undefined || options.showActions === true) && !this.modal && this.form.actions) {
|
||||
html += this.getActions(options);
|
||||
}
|
||||
|
||||
@ -1251,7 +1251,7 @@ angular.module('FormGenerator', ['GeneratorHelpers', 'Utilities', 'ListGenerator
|
||||
}
|
||||
|
||||
//buttons
|
||||
if (!this.modal) {
|
||||
if ((options.showButtons === undefined || options.showButtons === true) && !this.modal) {
|
||||
if (this.has('buttons')) {
|
||||
|
||||
if (this.form.twoColumns) {
|
||||
|
||||
@ -152,6 +152,8 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="inventory-edit-modal-dialog"></div>
|
||||
|
||||
<div ng-include="'/static/partials/logviewer.html'"></div>
|
||||
|
||||
</div>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user