Explorar o código

Fixed file explorer download one folder bug

TC pushbot 5 %!s(int64=4) %!d(string=hai) anos
pai
achega
b2050415f4
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      web/SystemAO/file_system/file_explorer.html

+ 1 - 1
web/SystemAO/file_system/file_explorer.html

@@ -2730,7 +2730,7 @@
                     var downloadURL = "/media?file=" + encodeURIComponent($(".fileObject.selected").attr("filepath")) + "&download=true";
                     var filename = $(".fileObject.selected").attr("filename");
                     generateDownloadFromURL(downloadURL,escape(filename));
-                }else if ($(".fileObject.selected").length > 1){
+                }else if ($(".fileObject.selected").length > 1 || ($(".fileObject.selected").length == 1 && $(".fileObject.selected").attr("type") == "folder")){
                     //Do zip and download for multiple files
                     $(".fileObject.selected").each(function(){
                         fileList.push($(this).attr("filepath"));