我正在过滤数组
$filter('filter')($scope.model.data, {dataType: term });
但是如何进行反向过滤 我想从显示中排除一些数据
$filter('filter')($scope.model.data, {dataType: 'wrongtype' }); // Exclude this type
类似$filter('excludefilter')($scope.model.data, {dataType: 'wrongtype' })
请提出建议
最佳答案
http://jsbin.com/jocane/3/edit?html,js,output
$scope.filterd = $filter('filter')($scope.allMyObjects, {name: '!rike' });
关于javascript - 如何在AngularJS Controller 中进行反向过滤,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24952997/