jQuery datatreeview events - maikelbos0/VDT GitHub Wiki
The jQuery-datatreeview provides events that you can subscribe to with the jQuery syntax.
<script type="text/javascript">
$('#example-treeview').on('datatreeview.selectionChanged', function (event, data, values) {
console.log(values);
})
</script>
-
datatreeview.selectionChanged
fires whenever the selection in a datatreeview changes; it provides the new selected data in its second parameter and the new selected values in its third parameter -
datatreeview.nodesExpanded
fires whenever treeview nodes are expanded; it provides the opened nodes in its second parameter -
datatreeview.nodesCollapsed
fires whenever treeview nodes is collapsed; it provides the closed nodes in its second parameter