I\'m trying to update a cell in jqgrid permanently upon loading. I know I can use setCell
but that only updates the value for that page. If I come back to the
I had a similar issue:
I needed to update a row upon a certain user-action (irrelevant).
For that, I needed to know the exact row from the 'data' object, even after some filtering of the table.
So I found a way to identify which row was changed - I added a RowID property for each item of the 'data' object, at the 'loadComplete' event:
loadComplete: function () {
if (firstRun) {
firstRun = false;
var dataArray = $('#jqGrid').jqGrid('getGridParam', 'data');
$(dataArray).each(function (index) {
dataArray[index].RowID = index + 1;
});
}
}
And now, at the formatter code, I was able to access rData.RowID to identify the exact row on which the action was taken, and to get/set its 'data' representation