存储之前过滤的数据 UIGIRD
Store the previous filtered data UIGIRD
有没有办法将以前过滤的数据存储在一个变量中,我像下面这样过滤数据:
$scope.filteredRows = $scope.gridApi.core.getVisibleRows($scope.gridApi.grid);
无论我在哪里创建值并进行这样的设置:
$scope.newVar = $scope.filteredRows;
我总是得到 $scope.filteredRows
第一次被过滤的当前过滤事件
您不应在范围内使用保存过滤器。使用隔离作用域或普通变量。那么就可以使用上面提到的angular.copy方法Claies
有没有办法将以前过滤的数据存储在一个变量中,我像下面这样过滤数据:
$scope.filteredRows = $scope.gridApi.core.getVisibleRows($scope.gridApi.grid);
无论我在哪里创建值并进行这样的设置:
$scope.newVar = $scope.filteredRows;
我总是得到 $scope.filteredRows
第一次被过滤的当前过滤事件
您不应在范围内使用保存过滤器。使用隔离作用域或普通变量。那么就可以使用上面提到的angular.copy方法Claies