var treeObj = $.fn.zTree.getZTreeObj("tree");
var nodes = treeObj.getSelectedNodes();
if(typeof nodes[0].children.length>0){
//为父节点
}
var treeObj = $.fn.zTree.getZTreeObj("tree");
var nodes = treeObj.getSelectedNodes();
if(typeof nodes[0].children.length>0){
//为父节点
}