Sortable Table

Discussions related to modeling and execution of forms.
Forum rules
Make sure every topic contains information about your LSPS version and if relevant also your server OS, client OS, database name and version, and application server name and version.
ssmelche
 
Posts: 36
Joined: Thu Mar 14, 2013 5:01 pm

Sortable Table

Fri Oct 23, 2015 5:53 pm

Hello,

I'm using LSPS 3.0.1014 and trying to make a sortable table. I followed the instructions at https://docs.whitestein.com/lsps/3_0/fo ... tabletable, but clicking on the sort icon on the table's column doesn't do anything other than change the sort icon arrow's direction.

What I'm unclear about is how does clicking on the columns update the List<OrderEnumeration> variable that is passed to the query?

How does the Table Column know which Enumeration to use for descending order when the user toggles the sort icon on the table column? I seem to only be able to put one enumeration value in the Ordering property of the Table Column.

I have attached screenshots of the query, the form variables, the table properties, and the table column properties for one of the columns that should be sortable.
Attachments
Table Properties.PNG
Table Properties.PNG (70.68 KiB) Viewed 2454 times
Form Variables.PNG
Form Variables.PNG (10.93 KiB) Viewed 2454 times
Query.PNG
Query.PNG (48.53 KiB) Viewed 2454 times

Byron Glueck
 
Posts: 85
Joined: Thu Apr 26, 2012 8:17 pm

Re: Sortable Table

Fri Nov 06, 2015 9:38 pm

Hello and thank you for your message.

Please refer to the current LSPS 3.x guidance for Table column sorting/ordering:
https://docs.whitestein.com/lsps/3_0/fo ... a_ordering

As an example, consider the following data type:

Screen Shot 2015-11-06 at 2.32.54 PM.png
Screen Shot 2015-11-06 at 2.32.54 PM.png (57.73 KiB) Viewed 2425 times


A Table component may be added to a Form with 2 Table Columns.
Detail: The Table Data Kind is set to Book.
Ordering: Infer Ordering is unmarked

Screen Shot 2015-11-06 at 2.33.35 PM.png
Screen Shot 2015-11-06 at 2.33.35 PM.png (114.24 KiB) Viewed 2425 times


The Title column may be ordered using Property: Book.title. The Author column may be ordered using Expression: { b:Book -> b.author.name }

Screen Shot 2015-11-06 at 2.33.54 PM.png
Screen Shot 2015-11-06 at 2.33.54 PM.png (91.62 KiB) Viewed 2425 times

Return to Forms

Who is online

Users browsing this forum: No registered users and 0 guests