With the latest release (including the fix you provided from the previous issue I reported), if you click the Import Grid button in the sample below, a javascript error occurs while trying to parse the output from jqGridExport:
$(function () {
var serializedGrid = null;
$("#myGrid").jqGrid({
datatype: "json",
url: '/Home/GetGridData',
jsonReader: {
repeatitems: false
},
colModel: [
{ name: "id" },
{ name: "FullName" }
],
multiselect: true,
loadComplete: function (data) {
serializedGrid = $("#myGrid").jqGridExport({ exptype: "jsonstring" });
}
});
$("#reloadButton").on("click", function (event) {
$("#myGrid").clearGridData();
$("#myGrid").trigger("reloadGrid");
});
$("#importGridButton").on("click", function (event) {
$("#myGrid2").jqGridImport({
imptype: 'jsonstring',
impstring: serializedGrid,
importComplete: function () {
alert("import done");
}
});
});
});
Copyright 2014 TriRand LtdAll Rights ReservedRSS
Back to Top