JQuery Tree Structure

I am using jquery.bassistance.de/treeview/ for my application. Can I expand the nodes only by clicking on the "+" icon. Currenty, even when I click on the text that appears after the “+” symbol, the tree expands.

+3
source share
1 answer

open jquery.treeview.js

find applyClasses: function(settings, toggler) { // TODO use event delegation this.filter(":has(>ul):not(:has(>a))").find(">span").unbind("click.treeview").bind("click.treeview", function(event) { // don't handle click events on children, eg. checkboxes if (this == event.target) toggler.apply($(this).next()); }).add($("a", this)).hoverClass();

and comment toggler.apply($(this).next());

+1
source

Source: https://habr.com/ru/post/1752085/


All Articles