Some data I'd like to sort but not have it be alphabetically.
For example: A, B, C, D
I'd like it to sort: D, A, C, B
With GravityForms we can enter the value for the label as a number. I'm thinking if we had an option to rename the label in GravityView - So 1=D, 2=A, 3=C, 4=B then we could accomplish this type of sorting.
If it helps anyone I achieved this with the following code:
In my case I'm using a dropdown field. Based on what the user selects I have (5) options that I want to sort and used a switch to enter the either a,b,c,d,e into a "Sorting" field that is hidden in the form.
The second part of the code updates the sorting field should the user update the entry.
Once you display the DataTable with the "Sorting" field you'll need to use CSS to hide the column.
Sounds like sorting according to the result of a formula (to be defined by the user). Would be a nice feature. Could this be achieved by adding a calculated field in the original form and then sorting by that field?
For maximum neatness, you would need to be able to sort the list by a field that was not actually shown in the list.