Closed maxiz closed 1 year ago
You can add this to your code: https://github.com/vakata/jstree/blob/master/src/misc.js#L724
Then configure it accordingly:
$('#jstree').jstree({
plugins : [ ... ,'select_all'],
select_all : { disabled : false, hidden : false },
...
I have a tree with some disabled nodes that are unselected. When I used select_all function to select all active nodes, I expected the disabled nodes to remain unselected. However, it seems select_all ignores the disabled state and selects all nodes. Maybe there should be a parameter to indicate whether or not to ignore disabled nodes. A separate function might be a better solution to prevent breaking existing code.
Line 3352 in jstree.js
this._data.core.selected = this._model.data[$.jstree.root].children_d.concat();
Changing it to filter out disabled nodes will fix the issue.