|
Title: scrollview causing infinite loop trying to fetch non-existent data Post by: tomhj on October 14, 2013, 03:59:06 PM I'm upgrading to the latest 1.3.4 jeasyui and want to convert several of my datagrids that use pagination to use virtual scrolling with "view: scrollview". I downloaded the datagrid-scrollview.js and installed it. It works pretty well except for the case where there are zero rows to return.
The scrollview/datagrid then goes into an infinite loop trying to fetch more data to fill the view - but the server-side is returning JSON saying there is no more data. This cycle continues until I kill my browser window. Code: $('#MyGrid').datagrid( { fit: true, pageSize: 40, url: 'GetData', view: scrollview, columns: [ (skipped for brevity) ] });Server side logging shows: GetData called GetData returns this JSON data: {"total":0,"rows":[]} GetData called again with additional parms: page=1 and rows = 40 GetData returns this JSON data: {"total":0,"rows":[]} GetData called again with additional parms: page=1 and rows = 40 etc... How can this be fixed? Title: Re: scrollview causing infinite loop trying to fetch non-existent data Post by: stworthy on October 14, 2013, 06:54:00 PM To fix this issue, please download the updated scroll view from http://www.jeasyui.com/extension/datagridview.php.
Title: Re: scrollview causing infinite loop trying to fetch non-existent data Post by: tomhj on October 15, 2013, 05:17:48 PM That fix works nicely for me - thanks!
I found another problem though with scrollview2 for virtual scrolling with detail expansion - I'll start another post for that one. |