This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal



Mar 11, 2011, 1:43 PM
149 Posts

Re: How to sort the repeat control (with a view as data source) ?

  • Category: Server Side JavaScript
  • Platform: All
  • Release: 8.5.2
  • Role: Developer
  • Tags: sorting,repeat,view
  • Replies: 5
 
The following should work
 
1. Create a view data source
2. Create a repeat control and refrence the view data source (view data source must be outside the repeat)
3. Make the columns in your view sortable
4. create a few links in the xpage for sorting, when clicking these links you can set a scoped variable that is used in the view data source "SortColumn" property
 
the result is that if you click one of the link you change the sortColumn of the view data source and the repeat is updated accordingly
 
 
hope it helps
Thomas
 
 
 
Mar 11, 2011, 3:33 PM
23 Posts
Re: How to sort the repeat control (with a view as data source) ?
Very clever.
 
I have had to provide similar solutions but had not thought of attacking it your way.
Mar 14, 2011, 8:53 AM
178 Posts
works great but how about both sorting options for a column?
Hej Thomas,
 
this approach works fine, except in case I want to have both sorting options for a column, how can I establish this?
 
(I can set a similar sortOrder for the viewdata, but value "both" does not give me so much)

This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal