How to update periodically paginated dgrid with server side Request collection

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

How to update periodically paginated dgrid with server side Request collection

alex.r
Hi,

I am trying to find a best way to update periodically paginated  dgrid 1.0 with data coming from Request-like collection using dstore 1.1.1.

Pagination extension is used in dgrid to paginate the data

At first I tried to call Dgrid.refresh() in function called from setInterval. However, that results in complete rebuilding of grid rows. The implementation of refresh()  removes all existing rows  and recreates them. Invoking refresh periodically creates  flickering effect.  

Is there any way in existing dgrid/dstore implementation to update only changed rows without removal and re-creation of not-changed rows?

I've seen couple other threads with similar issue where usage of Cache/Trackable collections was suggested to solve the flickering effect. However, it seems that combination of Cache/Trackable only make sense to use if you have all data loaded whilst in my case only portion of a data is requested from server and displayed in the grid.

I created a stackoverlow thread where I provided code samples demonstrating the problem
http://stackoverflow.com/questions/37414480/how-to-update-paginated-dgrid-periodically

Any help/advise is appreciated.

Kind Regards,
Alex