我有一个通过 Json 字符串传递到我的 JQGrid 中的日期,它看起来像
"31/10/2011"
我无法通过 JQGrid 计算格式 documentation .我只希望它出现,然后在网格中进行排序。
如果我在没有格式化的情况下发布,日期看起来不错,但不会被识别为日期,因此排序都是错误的。
如果我将以下日期格式添加到列中
formatter: 'date', formatoptions: { newformat: 'd/m/Y'}
我得到了一个看起来像这样的日期
03/10/2031
我一生都无法弄清楚问题是什么,请帮忙。
最佳答案
formatter: 'date', formatoptions: { srcformat: 'd/m/Y', newformat: 'd/m/Y'}
对问题进行排序
关于date - JQgrid json 日期格式,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10619570/