I have couple of jqgrids on a page..Now I want to reload both the jqgrids after i update a record in any of them.
Here is my body..
<div style="position: relative; top: 40px; width:50%">
<table id="list"><tr><td></td></tr></table>
<div id="pager"></div>
</div>
<div style="position: relative; top: -250px; left:50%;">
<table id="list1"><tr><td></td></tr></table>
<div id="pager1"></div>
</div>
and Here is the script for after submit function of first jqgrid...
afterSubmit: function (response, postdata)
{
if (response.responseText === "OK")
{
alert("Update is succefully");
alert(this);
$(this).jqGrid("setGridParam", {datatype: 'json'});
return [true, "", ""];
alert("#list1");
$("#list1").jqGrid("setGridParam", {datatype: 'json'});
return [true, "", ""];
// $(this).trigger('reloadGrid');
}
else {
alert("Update failed");
return [true, "", ""];
}
}
Now using this code my first jqgrid does get reloaded after updating data and shows updated data in that jqgrid, However second jqgrid which has id #list1 doesn't get reloaded/refreshed.How do I Achieve this?