diff --git a/src/main/resources/templates/admin/business/process-edit.ftl b/src/main/resources/templates/admin/business/process-edit.ftl index dcb7fb1..82e4011 100644 --- a/src/main/resources/templates/admin/business/process-edit.ftl +++ b/src/main/resources/templates/admin/business/process-edit.ftl @@ -126,7 +126,7 @@ - + @@ -308,9 +308,9 @@ 上传附件 <#--展示已经上传的文件-->
- - + {{attachment.name}} @@ -822,14 +822,14 @@ const processType = this.processType const supplierMaterialsForm = this.supplierMaterialsForm - if (fileList && fileList.length === 0) { - this.$message.error("未上传附件"); - return false - } - let validStatus = !needValid if (needValid) { // 校验表单 + if (fileList && fileList.length === 0) { + this.$message.error("未上传附件"); + return false + } + this.$refs["contractProcessForm"].validate((valid) => { if (valid) { if (processType === saleContract) { @@ -1074,6 +1074,8 @@ name: file.name }) + console.log(attachments) + console.log(scope.row['attachment']) this.$message.success("上传成功"); } else { diff --git a/src/main/resources/templates/admin/business/process-new.ftl b/src/main/resources/templates/admin/business/process-new.ftl index ec70c0f..8f0e773 100644 --- a/src/main/resources/templates/admin/business/process-new.ftl +++ b/src/main/resources/templates/admin/business/process-new.ftl @@ -233,7 +233,7 @@ - +
@@ -420,9 +420,9 @@ 上传附件 <#--展示已经上传的文件-->
- - + {{attachment.name}} @@ -990,12 +990,12 @@ this.$message.error("未选择项目"); return false } - if (fileList && fileList.length === 0) { - this.$message.error("未上传附件"); - return false - } let validStatus = !needValid if (needValid) { + if (fileList && fileList.length === 0) { + this.$message.error("未上传附件"); + return false + } // 校验表单 this.$refs["contractProcessForm"].validate((valid) => { if (valid) { @@ -1242,7 +1242,6 @@ handleSupplierMaterialFileUploaded(scope, response, file, fileList) { if (response.success) { - console.log(fileList) let attachments = scope.row['attachment'] if (isEmpty(attachments)) { attachments = [] @@ -1253,6 +1252,9 @@ name: file.name }) + console.log(attachments) + console.log(scope.row['attachment']) + this.$message.success("上传成功"); } else {