Multi column sort order

UI Components for JSF
Post Reply
bendicott
Posts: 11
Joined: 27 Mar 2015, 00:01

22 Feb 2017, 23:07

I'd like to have an initial sort order using multiple columns; say, if you look at the sort example on the showcase, I wanted to sort first by year, then refine by brand. Is there any example of how to achieve this, or would I be better off manually ordering the original list in my bean with a comparator?

pf v. 5.2, jsf impl v. 2.0.3

schlebe
Posts: 212
Joined: 25 Sep 2015, 13:32
Location: Colmar-Berg (Luxembourg)

23 Feb 2017, 09:41

Hello Bendicott,

I know a solution that consists to generate an hidden sort-column that contains a string equal to your multiple columns.

This is only a tips !

I'm also interesting to know if, by Primefaces, another solution (more elegant) exists !
PrimeFaces 6.2.4
Mojarra 2.2.13
Glassfish 4.1

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 52 guests