mirror of
https://github.com/nasa/openmct.git
synced 2025-04-15 23:16:46 +00:00
[Search] 'All' selected upon no filters. Fixes #1117
Upon deselecting every filter, the search returns nothing. This serves no useful purpose as discussed in #1117. Now deselecting every filter automatically selects 'All'.
This commit is contained in:
parent
eb3b6e5eca
commit
e29efbbcdf
@ -80,7 +80,7 @@ define(function () {
|
||||
// If there's still nothing in the filters string, there are no
|
||||
// filters selected
|
||||
if ($scope.ngModel.filtersString === '') {
|
||||
$scope.ngModel.filtersString = 'NONE';
|
||||
$scope.ngModel.checkAll = true;
|
||||
}
|
||||
}
|
||||
|
||||
@ -95,12 +95,11 @@ define(function () {
|
||||
$scope.ngModel.checked[type] = false;
|
||||
});
|
||||
|
||||
// Change the filters string depending on checkAll status
|
||||
if ($scope.ngModel.checkAll) {
|
||||
// This setting will make the filters display hidden
|
||||
$scope.ngModel.filtersString = '';
|
||||
} else {
|
||||
$scope.ngModel.filtersString = 'NONE';
|
||||
// This setting will make the filters display hidden
|
||||
$scope.ngModel.filtersString = '';
|
||||
// Do not let checkAll become unchecked when it is the only checked filter
|
||||
if (!$scope.ngModel.checkAll) {
|
||||
$scope.ngModel.checkAll = true;
|
||||
}
|
||||
|
||||
// Re-filter results
|
||||
|
Loading…
x
Reference in New Issue
Block a user