Tree API

Methods
checkItem checks the checkbox of a tree item and all its sub-items
close closes a tree item by id
closeAll closes all opened Tree items
collapse collapses a tree item by id
collapseAll collapses all expanded Tree items
destructor releases the occupied resources
editItem edits a Tree item
expand expands a tree item by id
expandAll expands all collapsed tree items
focusItem sets focus to a specified tree item
getChecked gets all checked tree items
getState gets the state of a tree
open opens a tree item by id
openAll opens all closed tree items
paint repaints Tree on a page
setState sets state for a tree
toggle opens/closes a tree item by id
uncheckItem unchecks the checkbox of a tree item and all its sub-items
unCheckItem unchecks the checkbox of a tree item and all its sub-items

Tree Collection

add adds an item to a component
canCopy checks whether it is possible to copy a control into some other control
copy adds a copy of an item and places it in the specified position
eachChild iterates through child items of a control
eachParent iterates through all the parent items (the immediate parent and its parent, etc until the parent is the component itself)
exists checks if the control exists
filter filters controls by some criteria
getId gets the ID of an item
getIndex gets the current position of an item
getItem gets an item by its ID
getItems gets the child items of a control
getLength counts child items of a control
getParent gets the ID of the parent of the control
getRoot returns the ID of the master component
haveItems checks whether an item has children
isSaved checks whether the changes made in a tree collection are saved to the server side
load loads items from a file
loadItems loads child items of a control from a file
move moves items to different positions
parse loads a collection of items from a local source
refreshItems refreshes child items of a control
remove removes an item
removeAll clears the component of all controls
restoreOrder restores the component to the state previous to sorting / filtering
save saves changes made in a tree collection to the server side
serialize returns a collection of all items
sort sorts controls according to some criteria
update changes an item
Events
afterCollapse fires after collapsing a tree item
afterExpand fires after expanding a tree item
beforeCollapse fires before collapsing a tree item
beforeExpand fires before expanding a tree item
itemClick fires on clicking a tree item
itemContextMenu fires on calling a context menu for a tree item on right click
itemDblClick fires on double-clicking a tree item
itemRightClick fires on right-clicking a tree item

Tree Collection

AfterAdd fires after adding a new item into a tree collection
AfterRemove fires after removing a new item from a tree collection
BeforeAdd fires before adding a new item into a tree collection
BeforeRemove fires before removing an item from a tree collection
Change fires when a tree collection is modified
Load fires when items are loaded in a tree collection
LoadError fires when loading of data fails
RemoveAll fires when all items are removed from a tree collection
Properties
autoload defines that the structure of a tree is being built while opening items
checkbox adds checkboxes to tree items
css adds a CSS class(es) to the component
data sets a dataset for a tree
dragCopy defines that an item is copied to a target during drag-n-drop
dragMode enables drag-n-drop in Tree
dropBehaviour defines the behaviour of a dragged item
editable enables editing of Tree items on a double-click
editing enables editing of Tree items on a double-click
icon allows adding custom icons for tree items
isFolder defines whether an item should be rendered as a folder
keyNavigation enables key navigation in a tree
Back to top