Hello Maksim,
I am using TreeTable and and doing update on the tree for one of the Row, but when I am doing in the below code, the code will throw an error and the control goes to this line in webix.js(Using debug JS)
var toporder = this.branch[parent];
this shows parent=true
and this.branch[parent]=undefind
First Exception comes in Catch -
First Time thowing from :
this.data.ungroup(true);
this.data.group(config);
Message : “Unable to get property ‘length’ of undefined or null reference”
Stack : "TypeError: Unable to get property ‘length’ of undefined or null reference
at _ungroup_tree
number : -2146823281
and the message comes like can not fine length of undefined, but again when the contole goes to Catch block this will start working.
I would request you please suggest me, what I can change so that this will work in first attempt.
try{
var serialize_treeData1 = global_root.$$("treeId").serialize();
console.log("serialize_treeData AFTER"+JSON.stringify(serialize_treeData1));
root.$$("treeId").ungroup();
root.$$("treeId").refresh();
console.log("parent node "+JSON.stringify(parentNode));
global_root.$$("treeId").group({by:"group"});
global_root.$$("treeId").openAll();
}catch(e){
try{
global_root.$$("treeId").group({by:"group"});
global_root.$$("treeId").openAll();
}catch(e1){
global_root.$$("treeId").group({by:"group"});
global_root.$$("treeId").openAll();
}
}