// 找出以后部门的子节点数
getDepth(json) {var arr = [];
arr.push(json);
var depth = 0;
while (arr.length > 0) {var temp = [];
for (var i = 0; i < arr.length; i++) {temp.push(arr[i]);
}
arr = [];
for (var i = 0; i < temp.length; i++) {for (var j = 0; j < temp[i].children.length; j++) {arr.push(temp[i].children[j]);
}
}
if (arr.length >= 0) {depth++;}
}
return depth;
}