Editor - issue with ordering of column with formatted dates
Editor - issue with ordering of column with formatted dates
Hi,
I'm using the Datatables Editor and am displaying a date in the format d/m/Y. I'm using the getFormatter() and setFormatter() (as per the examples) to signify the change between the mysql db format Y-m-d and the display format of d/m/Y and vice versa. The problem is that I'm also setting that column as the default order, and the date ordering is calculated on the display format which results in incorrect results. Is there a way to order a date column that isn't displayed in ISO8601 format?
Thanks
This question has an accepted answers - jump to answer
Answers
Hi,
The date / time sorting plug-in introduced on this page is the best way of handling non-ISO8601 formatted dates with client-side processing.
If you already have Moment.JS for the date / time picker loaded, that absolutely go for that method.
Allan
Great, thanks Allan