alfajango / jquery-dynatable

A more-fun, semantic, alternative to datatables
http://www.dynatable.com
Other
2.77k stars 361 forks source link

Sorting time duration content #129

Closed scottcsims closed 10 years ago

scottcsims commented 10 years ago

I have a time duration column I would like to sort. The data is in this format 1h:58m:0:s. I found an article on stack overflow where you can parse out the string and leave the int content but that could be tricky with 3 numeric values. Can you point me to documentation that could help me. Thanks!

scottcsims commented 10 years ago

I was able to create a hidden column in milliseconds, use a reader to convert it to a Number and then use data-dynatable-sorts=milliseconds in the for duration.