say have following ng-repeat:
<ul class="list-group"> <ng-user-item ng-repeat="user in users | filter:search" user="user" ng-if="assigned.indexof(user.id) < 0" ng-click="selectfunction(user);"></ng-user-item> </ul> now can see has filter.
when filter not null have following button:
<button class="btn btn-default" ng-if="search.division != null" style="margin-bottom: 10px;">select all</button> when button pressed want list of ng-user-item visible.
how can done angular?
i think if change ng-repeat should work:
ng-repeat="user in filteredusers = (users | filter:search)" you can use filteredusers normal scope variable.
Comments
Post a Comment