On colModel, is there any way to set the default value if the result is null, I mean:
colModel: [
{ name: 'Date', index: 'Date', width: 35, formatter: 'date', formatoptions: { newformat: 'd/m H:i' }, sorttype: 'date', **IFISNULLDISPLAY: '-'** }
]
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
It seems for me that you found a bug in iqGrid. here the variable
optswill be set tothen inside of date formatter (see here) the
optswill be extended toopwith respect offormatoptionsand in case of non-empty
cellvalwill be usedopThe bug is that in another line which will be executed for empty
cellvalit will be usedoptsinstead ofopThe line (it has the number 5054 and 5052 in the file
jquery.jqGrid.src.js) must be fixed toHow you can see from the demo the
defaultValue: '-'of theformatoptionsof the formatter: ‘date’ will work correct, but it is still not documented.