ztree 基本应用

阅读更多
参考资料:
http://www.treejs.cn/v3/main.php#_zTreeInfo


    zTreeObj2 = $.fn.zTree.init($("#treeDemo2"), setting2, zNodes);
    var zNodes = ${hrJson};
    var setting2 = {
        view: {
            selectedMulti: false
        },
        edit: {
            enable: false,
            editNameSelectAll: true,
            removeTitle: '删除 ',
            renameTitle: '重命名'
        },
        data: {
            keep: {
                parent: true,
                leaf: true
            },
            simpleData: {
                enable: true
            }
        }, callback: {
            onClick: zTreeOnClick2   //树单击事件
            /*onRename: zTreeOnRename*/
        }
    
    };
    

    你可能感兴趣的:(ztree 基本应用)