From 1360d2d0663cd9e5933b9eb57cd249f6f64c0030 Mon Sep 17 00:00:00 2001 From: Mr Chen Date: Wed, 25 Dec 2024 21:19:53 +0800 Subject: [PATCH] Update files.js --- web/static/app/files.js | 66 ++++++++++++++++++++--------------------- 1 file changed, 32 insertions(+), 34 deletions(-) diff --git a/web/static/app/files.js b/web/static/app/files.js index 75f1f79ab..d126a4c00 100755 --- a/web/static/app/files.js +++ b/web/static/app/files.js @@ -156,14 +156,14 @@ function recycleBin(type){ var tablehtml = '
\
\ - 文件回收站\ -
\ - \ - \ -
\ -
\ + 文件回收站\ +
\ + \ + \ +
\ +
\ 注意:关闭回收站,删除的文件无法恢复!\ - \ + \ \
\
\ @@ -290,7 +290,7 @@ function openFilename(obj){ } if (inArray(ext,['png','jpeg','jpg','gif','webp','bmp','ico'])){ - getImage(path); + getImage(path); } if (inArray(ext,['svg'])){ @@ -303,19 +303,19 @@ function openFilename(obj){ maxmin:true, shadeClose: true, content: '' + src="'+url+'"\ + frameborder="0"\ + border="0"\ + marginwidth="0"\ + marginheight="0"\ + scrolling="yes"\ + noresize=""\ + allowfullscreen="allowfullscreen"\ + mozallowfullscreen="mozallowfullscreen"\ + msallowfullscreen="msallowfullscreen"\ + oallowfullscreen="oallowfullscreen"\ + webkitallowfullscreen="webkitallowfullscreen"\ + allowfullscreen="true">' }); } } @@ -374,16 +374,15 @@ function getFiles(Path) { Path = getCookie('open_dir_path'); } - var args = {}; - args['p'] = p; var post = {}; post['path'] = Path; + post['p'] = p; var file_row = $.cookie('file_row'); if(!file_row) { file_row = '100'; } - args['row'] = file_row; + post['row'] = file_row; var body = ''; var totalSize = 0; @@ -392,13 +391,13 @@ function getFiles(Path) { var search_file = $("#search_file").val(); if(search_file.length > 0){ - args['search'] = search_file; + post['search'] = search_file; } var search_all = ''; var all = $('#search_all').hasClass('active'); if(all){ - args['all'] = 'yes'; + post['all'] = 'yes'; } var file_order = $.cookie('file_order'); @@ -406,10 +405,9 @@ function getFiles(Path) { post['order'] = file_order.replace('|',' '); } - var query_str = toUrlParam(args); var loadT = layer.load(); - $.post('/files/get_dir?' + query_str, post, function(rdata) { + $.post('/files/get_dir', post, function(rdata) { layer.close(loadT); //构建分页 @@ -1428,9 +1426,9 @@ function isCompressFile(fileName){ var extName = ext[ext.length-1].toLowerCase(); var support = ['zip','gz','tgz','rar']; for (x in support) { - if (support[x]==extName){ - return true; - } + if (support[x]==extName){ + return true; + } } return false; } @@ -1638,8 +1636,8 @@ function setChmod(action,fileName){
\
\ \ - \ -
\ + \ +
\ ' }); @@ -1717,7 +1715,7 @@ function rightMenuClick(type,path,name){ {text: "剪切", onclick: function() {cutFile(path)}}, {text: "重命名", onclick: function() {reName(0,name)}}, {text: lan.files.file_menu_auth, onclick: function() {setChmod(0,path)}}, - {text: lan.files.file_menu_zip, onclick: function() {zip(path)}}, + {text: lan.files.file_menu_zip, onclick: function() {zip(path)}}, ]}; if(type == "dir"){ options.items.push({text: lan.files.file_menu_del, onclick: function() {