easyui tree设置选中节点的方法

onLoadSuccess:  function  (node, data) {
     if  (data.length > 0) {
           //找到第一个元素
           var  n = $( '#menuTree' ).tree( 'find' , data[0].id);
           //调用选中事件
           $( '#menuTree' ).tree( 'select' , n.target);
           //调用其它函数
            display(data[0].id);
              }
       }, 

猜你喜欢

转载自blog.csdn.net/weixin_42350212/article/details/80877853