My date field field so that it has this format dd/mm/yyyy and not this yyyy-mm-dd format?
My date field field so that it has this format dd/mm/yyyy and not this yyyy-mm-dd format?
klermann
Posts: 277Questions: 67Answers: 1
Hello Allan, how should I format my date field field so that it has this format dd/mm/yyyy and not this yyyy-mm-dd format?
This question has accepted answers - jump to:
This discussion has been closed.
Answers
use momentjs plugin in the column render to format the date how you want.
Here is an example http://jsbin.com/didequg/edit?js,output , look and the columns section towards the top.
http://momentjs.com
See also this blog post.
Allan
Allan and in the editor how should I use this function!
The fact that Editor is being used on the same table should make no difference. You would use it in exactly the same way as described in the blog post I linked to.
Allan
Can you tell me why the date was not changed?
Required format is dd/mm/yyyy
I placed above the editor
The moment sorting plug-in won't effect Editor at all. It will effect the sorting.
I don't know where on your page that input element is. Is it a
datetime
field? If so use theformat
option that is documented for that field type.Allan