Hello,
I am working on implementing the Data Grid Web (for Traditional) and have hit a road block when it comes to setting primary, secondary, and tertiary sorting criteria.
I do see the Sorting Property that is available on the Grid Column. It gives me the option on Ascending, Descending, or NullTextIdentifier(). I have utilized this property for the columns in question that I am trying to sort, but by default it is sorting them in order starting with the column that is closest to the left. I need to be able to set a primary, secondary, and tertiary that is in a different order.
I am trying to accomplish two things:
1) I need the columns to stay in the order that they are currently in. This is a requirement that was given to me because we are replacing a table where the users are used to this order and they do not want to change it.
2) I also need to set a primary, secondary, and tertiary sort on columns that are not in that respective order from left to right.
See attachment for an example.
The reason why I think this should be possible is because when you utilize the manual sort setting (ctrl + click) to interact with the Data Grid, you can set the sort out of left to right order.
Is there a way to do this on the default view?
Hi @Nikki Burkhart,
Are you using the AutoGenerateColumns? If you do, you must to add the columns into the GridPlaceholder in the order you need, then you will be able to set that property for the columns you need.
Let me also say that the sort on click (single col sort) is an expected behaviour for the OutSystems Grid due to the shift click feature.
In order to better understand your use case, are you able to share an abstract oml with the approach you're following?
Cheers,JR
To have the community help you should always isolate the use case and share it on an oml since the community members will need that to do tests and try to provide a solution. It doesn't need (it shouldn't actually) to be the customer module.
To control the sort you can take a look at the input parameter Sorting present on the column blocks and use your business logic accordingly:
Also, for groups feel free to check the online sample where you have dedicated pages for these scenarios:
Cheer,GM