瀏覽代碼

!147 压缩包预览报错
Merge pull request !147 from xiaoyinkuangxue/master

陈精华 1 年之前
父節點
當前提交
19227fcbab
共有 1 個文件被更改,包括 4 次插入2 次删除
  1. 4 2
      server/src/main/resources/web/compress.ftl

+ 4 - 2
server/src/main/resources/web/compress.ftl

@@ -51,8 +51,10 @@
     };
 
     function chooseNode(event, treeId, treeNode) {
-        var path = '${baseUrl}' + treeNode.id +"?fileKey="+'${fileName}';
-        location.href = "${baseUrl}onlinePreview?url=" + encodeURIComponent(Base64.encode(path));
+        if (!treeNode.isParent) {
+            var path = '${baseUrl}' + treeNode.id + "?fileKey=" + '${fileName}';
+            location.href = "${baseUrl}onlinePreview?url=" + encodeURIComponent(Base64.encode(path));
+        }
     }
 
     $(document).ready(function () {