quick-ng-repeat icon indicating copy to clipboard operation
quick-ng-repeat copied to clipboard

Does it support filters and alias?

Open vbilici opened this issue 12 years ago • 4 comments

Hi, I have an expression like this: ng-repeat="event in filteredEvents = (comp.events | filter:listerSearch | xRange:filterXType.val:filterXMin:filterXMax | dateRange:filterStartDate:filterEndDate)"

how could it be possible to implement this in your directive ? Thanks.

vbilici avatar Nov 24 '13 08:11 vbilici

@vbilici have you tried the same expression with quick-ng-repeat? It uses the same parser with ng-repeat and I think they should be compatible.

The other approach is to save the expression result into the scope variable and use this variable (or function).

Anyway, let me know about your results, and if some fixes are needed in quick-ng-repeat directive.

allaud avatar Nov 24 '13 09:11 allaud

@allaud alias works as expected but there is a problem with filters. It doesn' t remove excluded elements and adds filtered element nex to old ones. So when you filter repeatedly multiple copies of the same element appears on the view.

vbilici avatar Nov 24 '13 11:11 vbilici

@vbilici I'm not sure I understand the problem and the reason. Maybe you can give a link to jsfiddle or you have some ideas how to fix it?

allaud avatar Nov 24 '13 18:11 allaud

@allaud for me filters are casuing inf digest loop.

Jurigag avatar Nov 03 '16 10:11 Jurigag