Dynamic orderBy in AngularJS

后端 未结 2 1691
忘了有多久
忘了有多久 2020-12-19 08:22

I have an array of objects I want to order dynamically, based on a value from a drop down menu. This is what I have so far in my list:

ng-repeat=\"item in fi         


        
2条回答
  •  死守一世寂寞
    2020-12-19 09:05

    So you have to create your own filter and do what ever you want in it, there's tons of example on google. Just search :

    angular custom filter

    Theses last days, i experience somes issues with filters creation and i found that: https://github.com/a8m/angular-filter

    I've added it immediately in my dependcies, i know i will use it really soon. May be it will help you too. Don't forget to valid my answer if it helps you to resolve your problem ;)

提交回复
热议问题