LINKeRxUA LINKeRxUA - 1 month ago 13
jQuery Question

JQuery "acitree" plugin. How to check/uncheck all?

How to check and uncheck all values from acitree plugin?
http://acoderinsights.ro/en/aciWorker-web-workers-jQuery - this is that plugin
but I can't find method to do something like check all and uncheck all

Answer

helps me:

var api = $('#tree').aciTree('api');
var leaves = $("#tree *");
var checkboxes = api.checkboxes(leaves);

checkboxes.each(function (index, item) {
    var $item = $(item);
    api.uncheck($item);
});