1
I’m doing a screen search modal of a system I’m doing, and I’m finding the following problem when it comes to implementing the filter: I’m filtering an array of objects in an ng-repeat, each object has 3 fields, but I want to filter just two, I tried to do a function like filter: getFiltered and filter through the 2 fields, but I could not save the filtered array in a variable.
$scope.getFiltered = function(items){
if(item.DescriptionSearch.indexOf($scope.comando.text) > -1){
return true;
}else if(item.Command != null){
if(item.Command.indexOf($scope.comando.text) > -1){
return true;
}
}else{
return false;
}
};
A question, where are you using the
items
that is as parameter?– DiegoAugusto