Open unle70 opened 1 year ago
Hello,
Sorry for delay. SetCell method uses a formatting, but there are conditions when this not apply.
See here: https://github.com/tonytomov/jqGrid/blob/master/js/grid.base.js#L6752
The conditions where the setCell fail are
Check if these conditions are correct.
Hi Tony,
Well, you pointed me to the interesting area in the code and then I did some debugging from there. Eventually I could see that the formatter IS being called, but the problem was elsewhere. My field is "datetime" type. When the setCell is called manually (like I use it), the formatter is invoked with the "edit" parameter. In that case there's a condition in the below line which needs "reformatAfterEdit" in order to use the formatter. Otherwise it uses the default formatter. Once I added "reformatAfterEdit : true" to my formatoptions, everything started working well. Not sure if this is a bug or just something to live with.
Anyway, thank you for the tip.
Looks to me that when using the "setCell" method, the value is going into the grid without applying the set formatter. My questions:
Thanks, Udi