Hi guys,
I have the following situation: I have a main grid which i populate from database and everything works just fine. On the same page
( document ) i have a toolbar of buttons whose clicks i have wired to creating a separate jqGrids. Basically each button represents a table in the database. When user clicks on a button, a currently displayed grid gets hidden using a wrapped div ( $(#”grid_wrapper1″).hide() ) then i create a new grid for the table which user has clicked on. Everything works, the grid is displayed correctly. The only problem is the pager. The 1st time user clicks on a button the pager navigation ( buttons and display message saying which page it is ) are placed correctly. Then, if user click again on the same table button, the pager slides/shifts down a little. Then again and again until it is simply out of view. Basically it goes completely down to the pager toolbar and i can't see it.
What am i doing wrong here? Do i have to GridUnload or GridDestroy each grid before creating it? Or is there a way of somehow clearing the pager contents and reloading it? Please help. Here is the code that i have:
function getCustomers() {
$(“#grid_wrapper2”).hide();
$(“#grid_wrapper1”).show();
}
function getContracts() {
$(“#grid_wrapper1”).hide();
$(“#contracts_grid”).jqGrid({
Copyright 2014 TriRand LtdAll Rights ReservedRSS
Back to Top