Datatable + sortable + checkbox selection multi

UI Components for JSF
Post Reply
User avatar
daniel_r
Posts: 199
Joined: 02 Mar 2009, 16:35

15 Jan 2012, 16:56

Hi

I had a sortable table, and then I have added

Code: Select all

<p:column selectionMode="multiple" />
+ all the other needed stuff too

I was expecting the checkboxes to stay selected after i hit the sort of the columns, bu the selected checkboxes are getting unselected each time I sort the columns,

Is it something that I didn't do the right way? Or its not supported?

Regards,

Daniel.
Primefaces 3.4 , MyFaces 2.0.11
Tomcat 6
Win7 32bit

ajesh
Posts: 38
Joined: 30 Jun 2011, 20:55
Location: Thiruvananthapuram, India

15 Jan 2012, 20:41

Yes, sortBy/filterBy is not supported combined with multiple selection and check box multiple selection. You can check that as "Wont Fix" flag on issue tracker. Because of that if we sort the datatable the index of selected item has to be changed. So the selected item vanishing..
For avoiding the row index sorting order, on primefaces 3 they have implemented rowKey concept.

As my concept, The rowKey is primary key database. So evenif we changed the order no problem, the item is selected using its rowKey. I think that can't implement correctly at this moment..
PrimeFaces 5.0 | Mojarra-2.2.6 | Spring 4.0 | Tomcat 7

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 20 guests