Type: New Feature
Affects Version/s: 2.2 M2 (Moore)
Fix Version/s: None
Add support for multiple fields and sorting in different directions, while supporting direct use of database fields. If the last string is asc|desc, it is the default sort direction:
field1_name desc, field2_name asc, field3Name desc ==>field1Name desc, field2Name asc, field3Name desc
field1_name, field2_name, desc ==>field1Name desc, field2Name desc
field1_name, field2_name asc, field3Name, desc ==>field1Name desc, field2Name asc, field3Name desc
- First of all, can be compatible with the original format
- Second, sometimes the page does not allow multiple sort parameters to be passed in, because this means that the dom structure needs to be dynamically added.
- Third, the new format (field name and sort syntax) is more in line with the habit of SQL.