mirror of
https://github.com/ansible/awx.git
synced 2026-05-10 10:57:35 -02:30
Hide smart inv button when no hosts exist. Updated disassociate tooltip. Filtered out the target group when associating existing groups
This commit is contained in:
@@ -110,7 +110,7 @@ export default ['i18n', function(i18n) {
|
|||||||
awToolTip: "Create a new Smart Inventory from search results.",
|
awToolTip: "Create a new Smart Inventory from search results.",
|
||||||
actionClass: 'btn List-buttonDefault',
|
actionClass: 'btn List-buttonDefault',
|
||||||
buttonContent: 'SMART INVENTORY',
|
buttonContent: 'SMART INVENTORY',
|
||||||
ngShow: 'canAdd',
|
ngShow: 'canAdd && (hosts.length > 0 || !(searchTags | isEmpty))',
|
||||||
dataPlacement: "top",
|
dataPlacement: "top",
|
||||||
ngDisabled: '!enableSmartInventoryButton'
|
ngDisabled: '!enableSmartInventoryButton'
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -99,7 +99,7 @@ export default {
|
|||||||
//label: 'Delete',
|
//label: 'Delete',
|
||||||
mode: 'all',
|
mode: 'all',
|
||||||
ngClick: "disassociateGroup(nested_group)",
|
ngClick: "disassociateGroup(nested_group)",
|
||||||
awToolTip: 'Delete group',
|
awToolTip: 'Disassociate group',
|
||||||
dataPlacement: "top",
|
dataPlacement: "top",
|
||||||
ngShow: "nested_group.summary_fields.user_capabilities.delete"
|
ngShow: "nested_group.summary_fields.user_capabilities.delete"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -23,6 +23,11 @@
|
|||||||
page_size: 5
|
page_size: 5
|
||||||
};
|
};
|
||||||
|
|
||||||
|
if($state.params.group_id) {
|
||||||
|
$scope.associate_group_default_params.not__id = $state.params.group_id;
|
||||||
|
$scope.associate_group_queryset.not__id = $state.params.group_id;
|
||||||
|
}
|
||||||
|
|
||||||
let list = _.cloneDeep(GroupList);
|
let list = _.cloneDeep(GroupList);
|
||||||
list.basePath = GetBasePath('inventory') + $state.params.inventory_id + '/groups';
|
list.basePath = GetBasePath('inventory') + $state.params.inventory_id + '/groups';
|
||||||
list.iterator = 'associate_group';
|
list.iterator = 'associate_group';
|
||||||
|
|||||||
Reference in New Issue
Block a user