jquery - How to check whether selected node is having child nodes or not in jstree? -



jquery - How to check whether selected node is having child nodes or not in jstree? -

i m taking selected node next code.

var selected=$("#warehousetree").jstree('get_selected');

and want check kid nodes selected node.

try this:

var tree = jquery.jstree._reference('#warehousetree'); var children = tree._get_children(selected);

which homecoming array of jquery objects of children of selected node.

jquery jstree

Comments

Popular posts from this blog

c# - Move local mssql database to webhosted MYSQL -

string - what is the difference between "some" == "some\0" and strcmp("some","some\0") in c++? -

java - How to pass parameters between Request-Scoped Controllers? -