JQgrid - no such method gridunload

2019-04-06 23:44发布

问题:

I am using latest version of jqGrid(4.8.2), and there are some strange:

  1. There is no file: grid.custom.js, in folder(or in github)

  2. In wiki(http://www.trirand.com/jqgridwiki/doku.php?id=wiki:methods) that method must be in file grid.custom.js

Finally, in source i can find method: gridUnload : function ( jqGridId ), and it's look similar(but you must call this method like this:

$.jgrid.gridUnload('jqGridKoeff');

But this situation is really strange. Be careful!

回答1:

There is a change in newer versions of the grid. Now you have to call GridUnload functions like the following:

$.jgrid.gridUnload(‘#jqGridId’); 

where jqGridId is the id of the grid