After node selection 'getActiveNodes()' returns empty array
Angular 2.4.4 Angular2-tree-component 3.1.0
After 2.8.0 -> 3.1.0 upgrade getActiveNodes() returns an empty array. In 2.8.0 this method returned an array of selected nodes.
Bug with getting number indexes as strings. Will be solved soon Thanks for reporting.
You can work with treeModel.activeNodeIds in the meantime until fixed, or keep track of the active nodes using events.
@adamkleingit thank you. I will switch to the new version after next more or less stable release.
Same here. activeNodeIds works fine.
Fixed in 3.2.1 - please upgrade
@adamkleingit thank you!
@adamkleingit Hi! I have the same issue and I am using the version ^5.0.0. I am using Angular v 4.4.0.
const nodes = tree.treeModel.getActiveNodes();
It is invoked when I click a button and I click this button when I already click some checkboxes but this code return me empty Array. Why?
If I use tree.treeModel.activateNodeIds I have the next return:
Object {$mobx: ObservableObjectAdministration}
PD: My ids are type number.
me too not working when I'm used getActiveNodes(); so I try with getFocusedNode() then it work and return node data.