From f148efa6e5db47eefc58d9699713a9b8bcb956f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A7=8B=E4=BA=8E=E5=88=9D=E8=A7=81?= <752204717@qq.com> Date: Tue, 19 Mar 2024 10:31:08 +0800 Subject: [PATCH] =?UTF-8?q?=E5=86=85=E5=AE=B9=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/common/common.vue | 2 +- src/views/modules/medical/general.vue | 1049 ++++++++++++++----------- src/views/modules/medical/light.vue | 17 +- 3 files changed, 608 insertions(+), 460 deletions(-) diff --git a/src/views/common/common.vue b/src/views/common/common.vue index c97af2b..a10bdba 100644 --- a/src/views/common/common.vue +++ b/src/views/common/common.vue @@ -1,5 +1,5 @@ - diff --git a/src/views/modules/medical/light.vue b/src/views/modules/medical/light.vue index 8f1df05..900af0f 100644 --- a/src/views/modules/medical/light.vue +++ b/src/views/modules/medical/light.vue @@ -386,7 +386,7 @@ export default { console.log("🚀 ~ .then ~ progress888:", progress); return progress; }, - handleRequest(option) { + handleRequest(option) { var that = this; const { onProgress, onSuccess, onError } = option; this.progressPercent = 0; @@ -400,7 +400,7 @@ export default { this.isUpload = true; - axios + axios .post(this.baseUrl + "/oss/fileoss/uploadFileSchedule", formdata) .then((res) => { console.log("🚀 ~ this.$axios.post ~ res111:", res); @@ -415,11 +415,10 @@ export default { that.fileList[that.fileList.length - 1].ststus = "error"; onError(); } - - }); - // var prom = new Promise((resolve, reject) => {}); - // prom.abort = () => {}; - // return prom; + }); + // var prom = new Promise((resolve, reject) => {}); + // prom.abort = () => {}; + // return prom; }, // 文件上传时的钩子函数,获取上传进度 @@ -580,6 +579,10 @@ export default { addOreEditCate() { this.$refs["addFormRef"].validate((valid) => { if (valid) { + if (this.isUpload) { + this.$message.error("文件正在上传中,请稍后..."); + return false; + } this.$http({ url: this.$http.adornUrl("/book/medicaldes/saveOrUpdateLight"), method: "post",