koalyptus / TableFilter

A Javascript library making HTML tables filterable and a bit more :)
https://www.tablefilter.com
MIT License
324 stars 94 forks source link

dataSortDesc #716

Closed dengf closed 5 years ago

dengf commented 5 years ago

Hi-

What is the key name in the configration to sepcify dateSortDesc? I went through the wiki and docs, but failed to find the instruction on so.

Thanks

dengf commented 5 years ago

Hi-- To clarify on my ask, I was trying to overload the sorted select options in filter. The data type for the value and I would like to be able to sort them in descending order. Thanks

koalyptus commented 5 years ago

@dengf, apologies for late reply due to parental leave. Please consider filter_options_sorter setting in https://github.com/koalyptus/TableFilter/wiki/1.05-Drop-down-filter, it allows you to implement your own sorter for the filter options. Cheers

koalyptus commented 5 years ago

@dengf, FYI v0.6.94 enhances filter options sorting logic and now supports date data type. Use the sort_filter_options_desc option to do so as shown in this example: https://codepen.io/koalyptus/pen/pmXqob

dengf commented 5 years ago

@koalyptus, Thanks a ton.