Explorar el Código

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

陈精华 hace 1 año
padre
commit
19227fcbab
Se han modificado 1 ficheros con 4 adiciones y 2 borrados
  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 () {