EasyUI Forum

General Category => Bug Report => Topic started by: arma on October 28, 2013, 10:01:38 PM



Title: Error Reloading Tree Grid
Post by: arma on October 28, 2013, 10:01:38 PM
Hi,

Is this a bug or i'm doing wrong in reloading tree grid? I need to relod tree grid based on username parameter. No paging.

mygrid.treegrid('reload', {username: 'myusername'});

it works for mygrid.treegrid('reload'); without additional param

It says :

Code:
Uncaught TypeError: Cannot read property 'children' of null jquery.easyui.min.js:9690
(anonymous function) jquery.easyui.min.js:9690
x.extend.each jquery.min.js:4
x.fn.x.each jquery.min.js:4
$.fn.treegrid.methods.reload jquery.easyui.min.js:9687
$.fn.treegrid


Title: Re: Error Reloading Tree Grid
Post by: arma on October 28, 2013, 10:11:14 PM
After reading this post, it can be applied to treegrid as well, using queryParams. It's solved.

http://www.jeasyui.com/forum/index.php?topic=2343.msg5239#msg5239

i'm still curious why it caused error. The doc says :

Reload treegrid data. If the 'id' parameter is passed, reload the specified tree row, otherwise reload all tree rows.
Code example:

$('#tt').treegrid('reload', 2);   // reload the row which value is equals to 2
$('#tt').treegrid('reload');   // reload the all rows
$('#tt').treegrid('reload', {id:2, q:'abc'});  // reload the specified row with 'q' parameter passing to server


Title: Re: Error Reloading Tree Grid
Post by: catpaw on January 21, 2014, 05:58:37 PM
I have same problem

did you resolve?


Title: Re: Error Reloading Tree Grid
Post by: arma on February 02, 2014, 12:44:51 AM
Yes it's resolved as i said in previous reply. It was solved using queryParams:{
    param1:'value1',
    param2:'value2'
  },