Closed JasonCSharpCoder closed 8 years ago
I have the same question.How to add a click event on the node of the tree?
you have the event of the js tree. Please check the js tree docs: https://www.jstree.com/api/#/
As ezraroi mentions, first, you need to check the events list. Then, you have to put it as follows:
In the HTML file:
< js-tree="treeConfig" tree-events="select_node:selectNode;open_node:openNode" />
In the Controller: $scope.selectNode = function(node, selected, event){ console.log(selected); }
$scope.openNode = function(node){ console.log(node); }
how to config or code a click event function for the tree node? thks!