ParamQuery grid support forum
General Category => Help for ParamQuery Pro => Topic started by: eloan on April 24, 2020, 01:43:51 pm
-
Hi.
Please help me.
I have upgraded the version of pqgrid from 3.3.4 to 7.0.0.
Then I get an error and am in trouble.
I used refreshDataAndView method.
Then, an error occurs in IE.
Call t at line 557 of pqgrid.dev.php, but t is undefined.
It does not occur in chrome or firefox.
It can be confirmed by displaying the "test simple html" below in the IE browser and "IE developer tool" and clicking the "refresh" link.
Best regards.
=== test simple html ===
<body>
<a href="#" onclick="refresh(); return false;">reload</a>
<div id="testGrid"></div>
<script>
function refresh() {
$("#testGrid").show();
$("#testGrid").pqGrid('option', 'dataModel.location', "remote");
$("#testGrid").pqGrid('option', 'dataModel.postData', []);
$("#testGrid").pqGrid('refreshDataAndView');
}
$(function() {
var colModel = [{"title":"ID","dataType":"string","dataIndx":"id"}
, {"title":"name","dataType":"string","dataIndx":"name"}
];
var dataModel = {"location":"remote"
,"dataType":"JSON"
,"method":"POST"
,"url":"https:\/\/paramquery.com\/pro\/orders\/get"};
var obj = {"width":"auto","height":"400","minHeight":"200","showTitle":true,"stripeRows":true,"showTop":false};
obj.colModel = colModel;
obj.dataModel = dataModel;
var grid = $("#testGrid").pqGrid(obj);
});
</script>
</body>
==================
-
Please mention version of IE, jQuery and jQueryUI.
-
IE version is 11.(debug mode 9 - 10, edge)
jquery version is 1.8.3
jquery-ui version is 1.12.1
-
dataModel.postData is not an array but a plain object or a function.
Please correct this
$("#testGrid").pqGrid('option', 'dataModel.postData', []);
to
$("#testGrid").pqGrid('option', 'dataModel.postData', {});
-
Thank you very much.
The problem is resolved.
It was helpful.