EasyUI Forum

General Category => EasyUI for jQuery => Topic started by: BinaryCode on June 09, 2013, 01:56:23 AM



Title: Search Tree
Post by: BinaryCode on June 09, 2013, 01:56:23 AM
Hi all,

how to do it on tree :

1. Search Text then checked or select (Problem Solve)
2. Check All Tree Node (parent/Childs)

Regards
B.C


Title: Re: Search Tree
Post by: stworthy on June 10, 2013, 06:18:37 AM
If the 'cascadeCheck' property is set to true, the simple way to check all nodes is to check the root nodes.
Code:
var t = $('#tt');
var roots = t.tree('getRoots');
for(var i=0; i<roots.length; i++){
  t.tree('check', roots[i].target);
}