数据结构如下:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 | var obj = { "childList" : [ { "id" : 2, "name" : "行政部门" , "parentId" : 1, "parentIds" : "0,1," , "childList" : [ { "childList" : [], "id" : 4, "name" : "校长室" , "parentId" : 2, "parentIds" : "0,1,2," , "userList" : [ { "id" : 111, "realName" : "杨武1" , "userName" : "admin" , "uuid" : "uuidtest1" } ] }, { "childList" : [], "id" : 5, "name" : "德育处" , "parentId" : 2, "parentIds" : "0,1,2," , "userList" : [ { "id" : 111, "realName" : "杨武(test)2" , "userName" : "yang" , "uuid" : "uuidtest2" }, { "id" : 222, "realName" : "杨武(test)3" , "userName" : "yang" , "uuid" : "uuidtest2" } ] } ], "userList" : [ { "id" : 333, "realName" : "杨武s" , "userName" : "admin" , "uuid" : "uuidtest1" }, { "id" : 444, "realName" : "杨武(test)s" , "userName" : "yang" , "uuid" : "uuidtest2" } ] }, { "id" : 3, "name" : "学科组" , "parentId" : 1, "parentIds" : "0,1," , "childList" : [ { "id" : 6, "name" : "文科组" , "parentId" : 3, "parentIds" : "0,1,3," , "childList" : [ { "id" : 6, "name" : "语文组" , "parentId" : 3, "parentIds" : "0,1,3," , "childList" : [ ], "userList" : [ { "id" : 555, "realName" : "杨武语文" , "userName" : "admin" , "uuid" : "uuidtest1" } ] }, { "id" : 6, "name" : "英语组" , "parentId" : 3, "parentIds" : "0,1,3," , "childList" : [], "userList" : [ { "id" : 444, "realName" : "杨武英语" , "userName" : "admin" , "uuid" : "uuidtest1" }, { "id" : 777, "realName" : "杨武(test)" , "userName" : "yang" , "uuid" : "uuidtest2" } ] } ], "userList" : [ { "id" : 888, "realName" : "杨武" , "userName" : "admin" , "uuid" : "uuidtest1" }, { "id" : 999, "realName" : "杨武(test)" , "userName" : "yang" , "uuid" : "uuidtest2" } ] }, { "id" : 6, "name" : "理科组" , "parentId" : 3, "parentIds" : "0,1,3," , "childList" : [], "userList" : [ { "id" : 1010, "realName" : "杨武" , "userName" : "admin" , "uuid" : "uuidtest1" }, { "id" : 1111, "realName" : "杨武(test)" , "userName" : "yang" , "uuid" : "uuidtest2" } ] } ], "userList" : [ { "id" : 1212, "realName" : "杨武(test)" , "userName" : "yang" , "uuid" : "uuidtest2" } ] } ], "id" : 1, "name" : "天心岛小学部门" , "parentId" : 0, "parentIds" : "0," , "userList" : [ { "id" : 1313, "realName" : "杨武" , "userName" : "admin" , "uuid" : "uuidtest1" } ] } |
1. 只需要根据树形结构数据就可以自动生成
特别申明:
本站所有资源都是由网友投稿发布,或转载各大下载站,请自行检测软件的完整性!
本站所有资源仅供学习与参考,请勿用于商业用途,否则产生的一切后果将由您自己承担!
如有侵权请联系我们删除下架,联系方式:lei1294551502@163.com