I checked $items among properties.
But there is a serious error.
Even if the child row is deleted through a function, $items does not change.
I want to check the existence of child row.
I checked $items among properties.
But there is a serious error.
Even if the child row is deleted through a function, $items does not change.
I want to check the existence of child row.
It was solved in the following way. Do you have any better way?
var temp =Treegrid.data.getItems(“parent_id”);
if(temp.getLength() ==0){
console.log(“is false”);
}else{
console.log(“is true”);
}
I have created two tree grids.
Grid A is empty.
Grid B has many rows. There is.
Move the rows from grid B to grid A.
Then I used the code below. treegridA.data.serialize(“json”);
The result is zero length.
Objects in grid A can see data normally.
Why doesn’t serialize work properly?
Thank you for your report.
The problem is confirmed. We’ll tr to fix it in one of the future updates.
As a workaround you may reset the child state manually with the:
const parent = treeGrid.data.getParent(row_id)
treeGrid.data.remove(row_id);
}
if (treeGrid.data.getItems(parent).length == 0) {
treeGrid.data.getItem(parent).$items = false
treeGrid.paint()
}
Hello.
we have fixed your reported problem in the latest dhx.Suite update (7.2.4).
Now the tree hierarchy should work correctly.