I don't want use ajax to load data in my grid. Theres a way to load all data to main grid and subgrids statically?
In the samples from jqGrid Documentation, the parameter subGridUrl
, is needed. But I want something like:
var mydata = [ {
// ... some static code for data creation here
} ]
and using mydata in parameter data
, but subGrid don't have this parameter or something else.
If you use subgrid as grid you have to create new grid inside of
subGridRowExpanded
callback. The callback getrowid
as a parameter. So if you would get the array of data which can be used asdata
parameter of the subgrid the subgrid can be defined withdatatype: 'local'
.The code schema can be about the following: