Skip to content Skip to sidebar Skip to footer

How To Iterate My Matrix When I Use A Filter

Hello everyone I am working with ArgularJs. I need to fix this problem, when I use a filter, I can't iterate my matrix to show its values into my table.

Solution 1:

charlietfl is right in pointing out that $scope.selectedCity is a string and cannot be used with ng-repeat, you need to give it an array.

I think what you are trying to do is:

<tr ng-repeat="item in cities[selectedCity]">

Updated jsfiddle: https://jsfiddle.net/bgg5yfot/1/

Post a Comment for "How To Iterate My Matrix When I Use A Filter"