Quellcode durchsuchen

资料归集,固定分类,显示文件夹

MaiXinRong vor 2 Jahren
Ursprung
Commit
92fb43f8d8
1 geänderte Dateien mit 3 neuen und 1 gelöschten Zeilen
  1. 3 1
      app/public/js/file_detail.js

+ 3 - 1
app/public/js/file_detail.js

@@ -28,13 +28,15 @@ $(document).ready(function() {
                 }
             });
             const sortNodes = this.dragTree.nodes.map(x => {
-                return {
+                const result = {
                     id: x.id,
                     tree_pid: x.tree_pid,
                     name: x.name + (x.total_file_count > 0 ? `(${x.total_file_count})` : ''),
                     spid: x.spid,
                     source_node: x,
                 };
+                if (result.source_node.is_fixed) result.isParent = true;
+                return result;
             });
             this.filingTree = $.fn.zTree.init($('#filing'), this.setting, sortNodes);
         }