angular-filter
angular-filter copied to clipboard
sorting by headers after using Group By Filter
here i want sort by group by clicking the header.
Can you provide more details or a Plunker?
this is my plunk
i am grouping three columns and showing results,
now i need to sort the data by click the header of those columns that are used to group and the data must be in group
http://plnkr.co/edit/uJilmFvMzJozlo2ujMte?p=preview
i have to sort header
Thanks, Raghu
On Wed, Jan 27, 2016 at 12:15 PM, Todd Branchflower < [email protected]> wrote:
Can you provide more details or a Plunker?
— Reply to this email directly or view it on GitHub https://github.com/a8m/angular-filter/issues/184#issuecomment-175778626.
ng-repeat="(key, value) in CrewHist | groupBy: '[Scheduler, Date, Time]' | orderBy:'+key'"
I'm not completely clear on what you're trying to do. But, reading through the groupBy
source, it does not support grouping by an array of properties.
Hi @pola2raghu, please take a look on this example: order-groupby-result. Thanks.
I am grouping multiple columns , In the example it has only one category,
In the example we have 2 ngrepeat's I need sort by parent $index
Thanks, Raghu
On Jan 28, 2016, at 4:20 AM, Ariel Mashraki [email protected] wrote:
Hi @pola2raghu, please take a look on this example: order-groupby-result. Thanks.
— Reply to this email directly or view it on GitHub.
Grouping is working fine with multiple key's
Order by is not working
Thanks, Raghu
On Jan 28, 2016, at 4:20 AM, Ariel Mashraki [email protected] wrote:
Hi @pola2raghu, please take a look on this example: order-groupby-result. Thanks.
— Reply to this email directly or view it on GitHub.
My bad @pola2raghu - think @a8m is right. Try this:
ng-repeat="(key, value) in CrewHist | groupBy: '[Scheduler, Date, Time]' | toArray:true | orderBy:'$key'"
Thanks it's ordering but I need to sort by headers
Thanks, Raghu
On Jan 28, 2016, at 11:26 AM, Todd Branchflower [email protected] wrote:
My bad @pola2raghu - think @a8m is right. Try this: ng-repeat="(key, value) in CrewHist | groupBy: '[Scheduler, Date, Time]' | toArray:true | orderBy:'$key'"
— Reply to this email directly or view it on GitHub.
I think this filter module should handle all common function like orderBy, sort ect. Without manipuling ourself the javascript