From 522320a3e3613258127505354c3202e4942a38a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AE=8B=E4=BC=9F=E4=BD=B3?= <2797716443@qq.com> Date: Fri, 22 Apr 2022 11:14:48 +0800 Subject: [PATCH] =?UTF-8?q?52651=20=E6=B8=85=E5=8D=95=E6=9B=B4=E6=96=B0?= =?UTF-8?q?=E5=8F=91=E5=B8=83=E6=B5=81=E7=A8=8B=20=E6=89=80=E6=9C=89?= =?UTF-8?q?=E8=8A=82=E7=82=B9=E9=83=BD=E6=B2=A1=E6=9C=89=E5=9C=A8=E7=BA=BF?= =?UTF-8?q?=E9=A2=84=E8=A7=88=E5=8A=9F=E8=83=BD=20=E5=BE=97=E5=8A=A0?= =?UTF-8?q?=E4=B8=8A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/creatProcess/bzqdfb/step1-1.vue | 88 +++++++++++---- .../pages/creatProcess/bzqdfb/step1.vue | 88 +++++++++++---- .../pages/creatProcess/bzqdfb/step3.vue | 101 ++++++++++++++---- 3 files changed, 216 insertions(+), 61 deletions(-) diff --git a/src/pages/processCenter/pages/creatProcess/bzqdfb/step1-1.vue b/src/pages/processCenter/pages/creatProcess/bzqdfb/step1-1.vue index 35b1d5dac..59ff0c487 100644 --- a/src/pages/processCenter/pages/creatProcess/bzqdfb/step1-1.vue +++ b/src/pages/processCenter/pages/creatProcess/bzqdfb/step1-1.vue @@ -49,22 +49,32 @@ > -
- - - 点击上传 - - + +
+
+
+ {{ item.name }} + +
+
+ + 点击上传 + @@ -699,17 +709,20 @@ @checkedRole="checkedRole" :nodeList="nodeList" > - +
@@ -793,6 +806,7 @@ export default { sarAccessListDatas: [], //国家地区清单表格 uploadFileListPath: "api/att/attFile/upload", // 上传的地址 fileInfoList: [], // 上传的附件 + fileInfo: '', // 展示的附件 fileIds: [], // 上传的附件 fileList: [], fileListName: [], //上传的附件名称 @@ -1191,6 +1205,16 @@ export default { this.fileInfoList.splice(index, 1); } }); + let list = '' + this.fileInfoList.forEach(item => { + if (list.length > 0) { + list += ',' + list += item.name + } else { + list+= item.name + } + }) + this.fileInfo = list }, fileUpload() { this.fileMadel = true; @@ -1204,6 +1228,16 @@ export default { this.$message.error(res.message); fileList.pop(); } + let list = '' + this.fileInfoList.forEach(item => { + if (list.length > 0) { + list += ',' + list += item.name + } else { + list+= item.name + } + }) + this.fileInfo = list }, // 相关附件 上传之前钩子 beforeUpload(file) { @@ -1243,6 +1277,18 @@ export default { }); window.open(routeUrl.href, "_blank"); }, + clickButtonToUpload2(file) { + const attId = file.attId + this.$preview(attId) + }, + clickButtonToUpload (file) { + const attId = file.attId + if (attId) { + window.location.href = '/api/att/attFile/downloadFileForSarNew?fileId=' + attId + } else { + this.$message.warning('文件不存在,下载失败') + } + }, // 导入标准数据成功后执行 importFileSuccess(response, file) { if (response.ok) { diff --git a/src/pages/processCenter/pages/creatProcess/bzqdfb/step1.vue b/src/pages/processCenter/pages/creatProcess/bzqdfb/step1.vue index d45ece1f4..34da50302 100644 --- a/src/pages/processCenter/pages/creatProcess/bzqdfb/step1.vue +++ b/src/pages/processCenter/pages/creatProcess/bzqdfb/step1.vue @@ -49,22 +49,32 @@ > -
- - - 点击上传 - - + +
+
+
+ {{ item.name }} + +
+
+ + 点击上传 + @@ -669,17 +679,20 @@ @checkedRole="checkedRole" :nodeList="nodeList" > - +
@@ -762,6 +775,7 @@ export default { sarAccessListDatas: [], //国家地区清单表格 uploadFileListPath: "api/att/attFile/upload", // 上传的地址 fileInfoList: [], // 上传的附件 + fileInfo: '', // 展示的附件 fileIds: [], // 上传的附件 fileListName: [], //上传的附件名称 standardData: [], //添加标准数据 @@ -1122,6 +1136,16 @@ export default { this.fileInfoList.splice(index,1) } }) + let list = '' + this.fileInfoList.forEach(item => { + if (list.length > 0) { + list += ',' + list += item.name + } else { + list+= item.name + } + }) + this.fileInfo = list }, fileUpload() { this.fileMadel = true; @@ -1135,6 +1159,16 @@ export default { this.$message.error(res.message); fileList.pop(); } + let list = '' + this.fileInfoList.forEach(item => { + if (list.length > 0) { + list += ',' + list += item.name + } else { + list+= item.name + } + }) + this.fileInfo = list }, // 相关附件 上传之前钩子 beforeUpload(file) { @@ -1174,6 +1208,18 @@ export default { }); window.open(routeUrl.href, "_blank"); }, + clickButtonToUpload2(file) { + const attId = file.attId + this.$preview(attId) + }, + clickButtonToUpload (file) { + const attId = file.attId + if (attId) { + window.location.href = '/api/att/attFile/downloadFileForSarNew?fileId=' + attId + } else { + this.$message.warning('文件不存在,下载失败') + } + }, // 导入标准数据成功后执行 importFileSuccess(response, file) { if (response.ok) { diff --git a/src/pages/processCenter/pages/creatProcess/bzqdfb/step3.vue b/src/pages/processCenter/pages/creatProcess/bzqdfb/step3.vue index 484587e3b..732b47a57 100644 --- a/src/pages/processCenter/pages/creatProcess/bzqdfb/step3.vue +++ b/src/pages/processCenter/pages/creatProcess/bzqdfb/step3.vue @@ -52,21 +52,32 @@ > - - - 点击上传 - - + +
+
+
+ {{ item.name }} + +
+
+
+ + 点击上传 +
@@ -381,6 +392,27 @@ @checkedRole="checkedRole" :nodeList="nodeList" > + + +
+ +

点击或拖拽上传文件

+
+
+
@@ -404,6 +436,7 @@ export default { // 当前流程类型(1待办/2已办) processType: 1, searching: false, + fileMadel: false, commentText:'', nodeList:[], isTransfer: false, @@ -436,6 +469,7 @@ export default { uploadFileListPath: 'api/att/attFile/upload', // 上传的地址 fileList:[], fileInfoList: [], // 上传的附件 + fileInfo: '', //展示的附件 dataList: [],//清单里的标准数据 standardData: [], //添加标准数据 standModel: false, // 选择标准抽屉状态 @@ -709,6 +743,19 @@ export default { this.fileInfoList.splice(index,1) } }) + let list = '' + this.fileInfoList.forEach(item => { + if (list.length > 0) { + list += ',' + list += item.name + } else { + list+= item.name + } + }) + this.fileInfo = list + }, + fileUpload() { + this.fileMadel = true; }, // 上传文件成功回调 uploadBackSuccess (res, file, fileList) { @@ -720,6 +767,16 @@ export default { this.$message.error(res.message) fileList.pop() } + let list = '' + this.fileInfoList.forEach(item => { + if (list.length > 0) { + list += ',' + list += item.name + } else { + list+= item.name + } + }) + this.fileInfo = list }, //上传之前的钩子 beforeUpload (file) { @@ -748,10 +805,16 @@ export default { } return true; }, - handleOnPreview(file) { - let attId = file.id - if (attId != null && attId !== "") { - window.location.href = "/api/att/attFile/downloadFileForSarNew?fileId=" + attId; + clickButtonToUpload2(file) { + const attId = file.id + this.$preview(attId) + }, + clickButtonToUpload (file) { + const attId = file.id + if (attId) { + window.location.href = '/api/att/attFile/downloadFileForSarNew?fileId=' + attId + } else { + this.$message.warning('文件不存在,下载失败') } }, getData() {