From c32dfb847e5c333ea788c07dea179be0e9a73bb7 Mon Sep 17 00:00:00 2001 From: LSH Date: 星期二, 07 十一月 2023 17:49:52 +0800 Subject: [PATCH] # --- src/main/webapp/static/js/plan/plan.js | 17 ++++++++++++----- 1 files changed, 12 insertions(+), 5 deletions(-) diff --git a/src/main/webapp/static/js/plan/plan.js b/src/main/webapp/static/js/plan/plan.js index ccc691d..b26f05c 100644 --- a/src/main/webapp/static/js/plan/plan.js +++ b/src/main/webapp/static/js/plan/plan.js @@ -246,7 +246,7 @@ var tr = $(['<tr id="upload-">' ,'<td id="upload-filename-id-'+ file.lastModified + '">' + file.name +'</td>' ,'<td>'+ (file.size/1014).toFixed(1) +'kb</td>' - ,'<td id="upload-file-id-' + file.lastModified + '">涓婁紶涓�</td>' + ,'<td id="upload-file-id-' + file.lastModified + '">鍑嗗涓婁紶</td>' ,'<td>' ,'<button class="layui-btn layui-btn-xs demo-reload layui-hide">閲嶄紶</button>' ,'<button class="layui-btn layui-btn-xs layui-btn-danger demo-delete">鍒犻櫎</button>' @@ -272,14 +272,20 @@ return false; } + var index = layer.load(1, { + shadeClose: false, + title: '涓婁紶涓�..', + shade: [0.5,'#000'] + }); + var file = _uploadFile + $("#upload-file-id-" + file.lastModified).html("涓婁紶涓�") - var filename = dateToStr2(new Date()) + "_" + file.name - $("#upload-filename-id-" + file.lastModified).html(filename) - - putObject(file, filename).then((result) => { + putObject(file).then((result) => { + var filename = result.name layer.msg('涓婁紶鎴愬姛', {icon: 1}); $("#upload-file-id-" + file.lastModified).html("涓婁紶鎴愬姛") + $("#upload-filename-id-" + file.lastModified).html(filename) $.ajax({ url: baseUrl+"/plan/insert/file/auth", @@ -292,6 +298,7 @@ method: 'POST', success: function (res) { if (res.code === 200){ + layer.close(index) console.log(res) } else if (res.code === 403){ top.location.href = baseUrl+"/"; -- Gitblit v1.9.1