My JqGrid code is as given below
$('#grid').jqGrid({
url: '',
scroll: 1,
postData: {
...
},
datatype: "json",
mtype: 'POST',
colNames: [....],
colModel: [{
name: 'source',
index: 'source',
width: '100',
align: 'center',
stype: 'select',
searchoptions: {
dataUrl: 'getSource'
}
}, { ...
}],
rowNum: 200,
height: '450px',
autowidth: false,
shrinkToFit: true,
rownumbers: true,
pager: '#table-page',
sortname: '...',
viewrecords: true,
sortorder: 'asc',
caption: "Records",
emptyrecords: "Empty records",
loadonce: false,
loadComplete: function() {
....
},
jsonReader: {
....
}
});
When I scroll the grid slowly and reach 200 the grid reloads but the view shows View 1-400 of 2000.
If I keep scrolling slowly then I see View 1-600 of 2000.
We can also see that in demo http://www.trirand.com/blog/jqgrid/jqgrid.html -> New in 3.7 -> True Scrolling and see the same bug.
Can someone please suggest me a workaround.
Its working as designed … if you scroll slowly it adds records to the table – so you can scroll up and the data is still present – if you scroll fast the current data is removed and only the new data is added using the number of rows you specify at a starting point matching the scroll position