Commit 45e19c79b19fcb179d4aea649c97ebff01b73521
1 parent
1711d03c
update
Showing
6 changed files
with
22 additions
and
14 deletions
src/main/resources/static/pages/control/line/js/home.js
src/main/resources/static/pages/permission/module/add_dir.html
| ... | ... | @@ -61,7 +61,7 @@ |
| 61 | 61 | </div> |
| 62 | 62 | </div> |
| 63 | 63 | </div> |
| 64 | -<script> | |
| 64 | +<script data-exclude=1> | |
| 65 | 65 | $(function() { |
| 66 | 66 | |
| 67 | 67 | //modal 显示事件 |
| ... | ... | @@ -153,5 +153,9 @@ |
| 153 | 153 | cb && cb(); |
| 154 | 154 | }); |
| 155 | 155 | } |
| 156 | + | |
| 157 | + function getCurrSelNode(){ | |
| 158 | + return $.jstree.reference("#modules_tree").get_selected(true); | |
| 159 | + } | |
| 156 | 160 | }); |
| 157 | 161 | </script> |
| 158 | 162 | \ No newline at end of file | ... | ... |
src/main/resources/static/pages/permission/module/add_modal.html
| ... | ... | @@ -147,7 +147,7 @@ |
| 147 | 147 | <script id="res_tbody_temp" type="text/html"> |
| 148 | 148 | |
| 149 | 149 | </script> |
| 150 | -<script> | |
| 150 | +<script data-exclude=1> | |
| 151 | 151 | $(function() { |
| 152 | 152 | var groupData = [] |
| 153 | 153 | ,dirGroupMapp = {};//目录到组的映射 |
| ... | ... | @@ -366,5 +366,8 @@ |
| 366 | 366 | }); |
| 367 | 367 | } |
| 368 | 368 | |
| 369 | + function getCurrSelNode(){ | |
| 370 | + return $.jstree.reference("#modules_tree").get_selected(true); | |
| 371 | + } | |
| 369 | 372 | }); |
| 370 | 373 | </script> |
| 371 | 374 | \ No newline at end of file | ... | ... |
src/main/resources/static/pages/permission/module/edit_dir.html
| ... | ... | @@ -62,7 +62,7 @@ |
| 62 | 62 | </div> |
| 63 | 63 | </div> |
| 64 | 64 | </div> |
| 65 | -<script> | |
| 65 | +<script data-exclude=1> | |
| 66 | 66 | $(function() { |
| 67 | 67 | |
| 68 | 68 | //modal 显示事件 |
| ... | ... | @@ -165,5 +165,9 @@ |
| 165 | 165 | } |
| 166 | 166 | } |
| 167 | 167 | } |
| 168 | + | |
| 169 | + function getCurrSelNode(){ | |
| 170 | + return $.jstree.reference("#modules_tree").get_selected(true); | |
| 171 | + } | |
| 168 | 172 | }); |
| 169 | 173 | </script> |
| 170 | 174 | \ No newline at end of file | ... | ... |
src/main/resources/static/pages/permission/module/edit_modal.html
| ... | ... | @@ -86,7 +86,7 @@ |
| 86 | 86 | </div> |
| 87 | 87 | </div> |
| 88 | 88 | </div> |
| 89 | -<script> | |
| 89 | +<script data-exclude=1> | |
| 90 | 90 | $(function() { |
| 91 | 91 | |
| 92 | 92 | var groupData = [] |
| ... | ... | @@ -224,5 +224,9 @@ $(function() { |
| 224 | 224 | } |
| 225 | 225 | } |
| 226 | 226 | } |
| 227 | + | |
| 228 | + function getCurrSelNode(){ | |
| 229 | + return $.jstree.reference("#modules_tree").get_selected(true); | |
| 230 | + } | |
| 227 | 231 | }); |
| 228 | 232 | </script> |
| 229 | 233 | \ No newline at end of file | ... | ... |
src/main/resources/static/pages/permission/module/list.html
| ... | ... | @@ -75,11 +75,10 @@ |
| 75 | 75 | </div> |
| 76 | 76 | </div> |
| 77 | 77 | </div> |
| 78 | -<script> | |
| 78 | +<script data-exclude=1> | |
| 79 | 79 | |
| 80 | 80 | $(function(){ |
| 81 | 81 | getTreeData(function(treeData){ |
| 82 | - console.log(treeData); | |
| 83 | 82 | |
| 84 | 83 | //初始化树 |
| 85 | 84 | $('#modules_tree') |
| ... | ... | @@ -169,13 +168,7 @@ $(function(){ |
| 169 | 168 | }); |
| 170 | 169 | |
| 171 | 170 | function getCurrSelNode(){ |
| 172 | - var array = []; | |
| 173 | - try { | |
| 174 | - array = $.jstree.reference("#modules_tree").get_selected(true); | |
| 175 | - } catch (e) { | |
| 176 | - console.log(e); | |
| 177 | - } | |
| 178 | - return array; | |
| 171 | + return $.jstree.reference("#modules_tree").get_selected(true); | |
| 179 | 172 | } |
| 180 | 173 | |
| 181 | 174 | function openTree_all(){ | ... | ... |