make it work in ng-repeat