禁用treepanel子ExtJ上的复选框

时间:2015-03-05 09:33:26

标签: javascript extjs checkbox

我在extjs视图中有treepanel代码,这里是:

createTreePaketExist: function() {
        var groupProduct = Ext.create('Ext.tree.Panel', {
            store       : 'TreePaketModif',
            queryMode   : 'local',
            itemId      : 'treeProduct',
            renderTo    : Ext.getBody(),
            name        : 'treeProduct',
            rootVisible : false,
            useArrows   : true,
            layout      :'fit',
            margin      : '0 0 0 0',
            autoScroll  : true,
            height      : 150,
            width       : '63%',
            listeners: 
            {
                checkchange: function(node, checked, eOpts){
                if (node.isLeaf()) {
                    node = node.parentNode;
                    var siblingStateEqual = true;
                    if (node.childNodes.length == 1) {
                        siblingStateEqual = checked;
                    } else {
                        node.cascadeBy(function(n) {
                        if (n != node) {
                            if (n.get('checked') != checked) {
                            siblingStateEqual = false;
                            }
                        }
                        });
                    }

我的结果是这样的:
enter image description here
我想禁用或删除Program Indihome 1000 menit-IN1000中的复选框,我必须添加或编辑哪些内容? 感谢..

0 个答案:

没有答案