ParamQuery grid support forum
General Category => Help for ParamQuery Pro => Topic started by: resolvecomputing on March 12, 2018, 02:10:31 pm
-
Dear team
When i change data i call to pq.grid() with new data i have this message "Uncaught use treeOption() to set treeModel options.", and when i select input selected i call again and then issue came again. i don't know why? Please help me. follow my code at this link https://plnkr.co/edit/0yb0Nk5AvOcHEXAjPLMI?p=preview (https://plnkr.co/edit/0yb0Nk5AvOcHEXAjPLMI?p=preview) . You can see the error message in console of browse.
Thank you so much!
-
There is a need to destroy the grid before passing a completely new set of options.
$('#change-data').change(function() {
var reportDate = $(this).val();
var obj = gridView(reportDate=="data1"?data1: data2);
$("#coa-table-tree").pqGrid('destroy')
pq.grid("#coa-table-tree", obj);
})
https://plnkr.co/edit/xZvUTEnM39JouKRaOQ6J?p=preview