问题
We are having a JQgrid with 3 level grouping applied. When we load the grid for the first time the column sum is getting rolled up successfully. We need to perform inline edit in the row and want the Group summary rows to get updated with the new value added. We have tried reloading the grid on aftersavefunc of editRow method but it is replacing the grid data with the server data. Is there a way we can refresh the Group summary row data when row is edited.
Thanks.
回答1:
You can, for example, reload the grid after the end of inline editing.
inlineEditing: {
keys: true,
aftersavefunc: function () {
var $self = $(this);
setTimeout(function () {
$self.trigger("reloadGrid");
}, 0);
}
}
It's recommended to use inlineEditing
option in free jqGrid to set inline editing option. See https://jsfiddle.net/oyavoe00/2/
来源:https://stackoverflow.com/questions/47160875/updating-groupsummary-row-in-jqgrid-on-editing