This project is read-only.

Very Simple Ajax Modification

May 26, 2014 at 9:03 AM
Me and my friend modified this library a little bit to make it more "ajax"
Modification ensures that only grid div is refreshed on paging and filtering. No extra modifiactions in code required. This is very simple. We just replaced window.location with ajax call. and on each request we are reinitializing grid.
It works. Is it very clean? Well I'm not sure.
Json transport would be probably more effective.

Well. I cant attach a files so :

Basicaly you have to just replace gridmvc.js and _Grid.cshtml
You also need to remove gridmvc.min.js
May 31, 2014 at 4:11 PM

Looks ok.

But you don't need to use custom container div (<div id="gridDiv" >), use current grid container:
this.jqContainer.load(document.URL +"?"+ initialUrl + url + " .grid-mvc", initGrid);
Also, if multiple grids on the page, after loading markup - you need to filter DOM elements by data-gridname attribute.
Jun 15, 2014 at 6:08 PM
Could you share like which places you modify? So it will work for future patch as well instead of just putting in the whole file like now. Thanks.