Reputation: 329
Hi, Everythink perfect without datetime on jqGrid :S How to fix this convertion problem?
Upvotes: 1
Views: 1282
Reputation: 349
These column properties worked for me
formatter: "date", formatoptions: { newformat: "ISO8601Long" }
Upvotes: 0
Reputation: 3277
You will need to set the formatter to date in your colModel and jqGrid will automatically detect the Microsoft date format.
The srcformat is not needed to be set, but newformat can be.
Try this:
colModel : [
...
{name:'Mydate', ...formatter: 'date', formatoptions:{newformat 'm/d/Y'}, ...},
...
]
Upvotes: 0
Reputation: 483
You can try this in your ColModel
{name: 'colNmae', index: 'ColName', formatoptions: { srcformat: "ISO8601Long", newformat: "m/d/Y h:i A" }}
Or this
{name: 'colNmae', index: 'ColName', sorttype: 'date', formatter: 'date', datefmt: 'd-M-Y'},
Upvotes: 1