diff --git a/src/main/resources/templates/admin/business/process-completed.ftl b/src/main/resources/templates/admin/business/process-completed.ftl index 19cb941..b5f7f51 100644 --- a/src/main/resources/templates/admin/business/process-completed.ftl +++ b/src/main/resources/templates/admin/business/process-completed.ftl @@ -23,6 +23,10 @@ .el-radio-button__inner, .el-radio-group { line-height: unset; } + + [v-cloak] { + display: none; + }
@@ -32,9 +36,9 @@ 已办流程
-
+
- +
@@ -126,7 +130,7 @@
- + {{processForm.applyDeptLeaderName}} - + @@ -500,8 +501,8 @@ } // @formatter:on - const applyDept = process.applyDept.split(',') - this.initForm({ ...form, ...process, ...contract, applyDept }) + const applyDeptId = process.applyDept.split(',') + this.initForm({ ...form, ...process, ...contract, applyDeptId }) this.projectSelected = true this.processType = process.processType this.incomeDetails = incomeDetails.map(detail => ({ @@ -532,26 +533,26 @@ saveDraft() { this.processForm.status = 'draft' - this.submit() + this.submit(false) }, submitForm() { this.processForm.status = 'to_be_audit' - this.submit() + this.submit(true) }, - submit() { + submit(needValid) { this.$refs["contractProcessForm"].validate((valid) => { - if (valid) { + if (valid || !needValid) { const fileList = this.fileList - if (fileList.length === 0) { + if (needValid && fileList.length === 0) { this.$message.error("未上传附件"); return false } const processType = this.processType const processForm = this.processForm - if (processType === 'procurement_contract') { + if (needValid && processType === 'procurement_contract') { const { procurementMode } = processForm // specify_purchase("指定采购"), @@ -562,7 +563,15 @@ if (procurementMode === 'price_comparison' || procurementMode === 'competitive_evaluation') { + if (isEmpty(this.supplierMaterialsForm)) { + this.$message.error("供应商比选材料未填写") + return false + } for (const item in this.supplierMaterialsForm) { + if (isEmpty(Object.keys(item))) { + this.$message.error("供应商比选材料未填写") + return false + } for (const [key, value] of Object.entries(item)) { if (value) { if (typeof value === 'string') { @@ -584,19 +593,19 @@ } } - if (!processForm.applyDeptId) { + if (needValid && !processForm.applyDeptId) { this.$message.error("申请部门还未选择"); return false } const loading = this.$loading({ lock: true, - text: '正在提交', + text: processForm.status === 'draft' ? '正在保存草稿' : "正在提交", spinner: 'el-icon-loading', background: 'rgba(0, 0, 0, 0.7)' }) - const applyDeptId = processForm.applyDeptId.map(level => level.id).join(',') // (逗号分割) + const applyDeptId = processForm.applyDeptId.join(',') // (逗号分割) const form = { ...this.processForm, diff --git a/src/main/resources/templates/admin/business/process-new.ftl b/src/main/resources/templates/admin/business/process-new.ftl index b264d2a..04a819a 100644 --- a/src/main/resources/templates/admin/business/process-new.ftl +++ b/src/main/resources/templates/admin/business/process-new.ftl @@ -157,7 +157,8 @@ 未选择部门 - + @@ -297,7 +298,7 @@ - + - +