I am trying to enable/disable grouping dynamically on a jqGrid on a button click, but it does not seem to be working. I am trying with this code but no luck
$('#mybutton').click(function(){
$('#mygrid').jqGrid('setGridParam', { grouping:true });
});
The grouping is generated with the following
groupingView : {
groupField : ['product'],
groupColumnShow : [true],
groupText : ['<b>{0}</b>']
}
Thanks!
Grouping feature has some method which you could use:
groupingRemove,groupingGroupBy,groupingToggle.To remove the grouping you can use
(where
var grid = $('#list');). To enable grouping you can use the code likeor for example