mirror of
https://github.com/ansible/awx.git
synced 2026-01-14 19:30:39 -03:30
Merge pull request #7144 from mabashian/6954-host-associate
Fixed group/host association across pages
This commit is contained in:
commit
4eaa12dd48
@ -63,11 +63,9 @@
|
||||
$scope.$watchCollection('associate_groups', function () {
|
||||
if($scope.selectedItems) {
|
||||
$scope.associate_groups.forEach(function(row, i) {
|
||||
$scope.selectedItems.forEach(function(selectedItem) {
|
||||
if(selectedItem.id === row.id) {
|
||||
$scope.associate_groups[i].isSelected = true;
|
||||
}
|
||||
});
|
||||
if ($scope.selectedItems.filter(function(e) { return e.id === row.id; }).length > 0) {
|
||||
$scope.associate_groups[i].isSelected = true;
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
@ -60,7 +60,7 @@
|
||||
$scope.$watchCollection('associate_hosts', function () {
|
||||
if($scope.selectedItems) {
|
||||
$scope.associate_hosts.forEach(function(row, i) {
|
||||
if (_.includes($scope.selectedItems, row.id)) {
|
||||
if ($scope.selectedItems.filter(function(e) { return e.id === row.id; }).length > 0) {
|
||||
$scope.associate_hosts[i].isSelected = true;
|
||||
}
|
||||
});
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user