diff --git a/src/common/lang/workCenter/en.js b/src/common/lang/workCenter/en.js
index ad4dcf8a..a58a020d 100644
--- a/src/common/lang/workCenter/en.js
+++ b/src/common/lang/workCenter/en.js
@@ -249,7 +249,8 @@ module.exports = {
solicitOpinionObject: '征求意见对象',
isCountersign: '是否会签',
countersignRelevantPersonnel: '会签相关人员',
- downloadTemplate: '企标稽查计划导入模板'
+ downloadTemplate: '企标稽查计划导入模板',
+ pleaseFillOpinion: '请填写意见'
},
// 企标稽查流程
esInspectionProcess: {
@@ -279,7 +280,9 @@ module.exports = {
rectificationPlanDoneDate: '整改计划完成日期',
rectificationRealityDoneDate: '整改实际完成日期',
rectificationStatus: '整改状态',
- pleaseFillInspectionContent: '请填写稽查内容'
+ pleaseFillInspectionContent: '请填写稽查内容',
+ pleaseFillInspectionReport: '请填写稽查报告',
+ pleaseFillRectificationPlan: '请填写整改计划'
},
// 稽查延期申请流程
incExtensionRequest: {
diff --git a/src/common/lang/workCenter/zh.js b/src/common/lang/workCenter/zh.js
index f4c45307..7b5b14da 100644
--- a/src/common/lang/workCenter/zh.js
+++ b/src/common/lang/workCenter/zh.js
@@ -283,7 +283,8 @@ module.exports = {
solicitOpinionObject: '征求意见对象',
isCountersign: '是否会签',
countersignRelevantPersonnel: '会签相关人员',
- downloadTemplate: '企标稽查计划导入模板'
+ downloadTemplate: '企标稽查计划导入模板',
+ pleaseFillOpinion: '请填写意见'
},
// 企标稽查流程
esInspectionProcess: {
@@ -313,7 +314,9 @@ module.exports = {
rectificationPlanDoneDate: '整改计划完成日期',
rectificationRealityDoneDate: '整改实际完成日期',
rectificationStatus: '整改状态',
- pleaseFillInspectionContent: '请填写稽查内容'
+ pleaseFillInspectionContent: '请填写稽查内容',
+ pleaseFillInspectionReport: '请填写稽查报告',
+ pleaseFillRectificationPlan: '请填写整改计划'
},
// 稽查延期申请流程
incExtensionRequest: {
diff --git a/src/views/workCenter/enterpriseStandardInspectionPlan/EnterpriseStandardInspectionPlanFlow.vue b/src/views/workCenter/enterpriseStandardInspectionPlan/EnterpriseStandardInspectionPlanFlow.vue
index a225adbc..c52f7354 100644
--- a/src/views/workCenter/enterpriseStandardInspectionPlan/EnterpriseStandardInspectionPlanFlow.vue
+++ b/src/views/workCenter/enterpriseStandardInspectionPlan/EnterpriseStandardInspectionPlanFlow.vue
@@ -349,9 +349,15 @@ export default {
async getPageParams (isValidate = true) {
// 去除备注必填
this.validatorRules.remarks.rules[0].required = false
+ // 报错标记(base基本信息校验失败,user人员信息校验失败)
+ let flag = ''
+ const base = 'base'
+ const user = 'user'
if (isValidate && this.$refs.inspectionPlanTable.dataSource.length === 0) {
this.$message.warning(this.$t('addAtLeastOneRowOfData'))
- throw new Error('base')
+ if (!flag) {
+ flag = base
+ }
}
// 节点2,验证所有数据意见是否都已填写
if (isValidate && this.currentNode === EsInspectionPlan.fillInComments.value) {
@@ -368,8 +374,10 @@ export default {
}
})
if (opinionHasEmpty) {
- this.$message.warning(this.$t('pleaseCompleteTableInfo'))
- throw new Error('base')
+ this.$message.warning(this.$t('workCenter.esInspectionPlan.pleaseFillOpinion'))
+ if (!flag) {
+ flag = base
+ }
}
}
const params = {}
@@ -383,7 +391,13 @@ export default {
// 收集所有表单信息
let formDataList = []
if (isValidate) {
- formDataList = await this.validateFormList(this.processInfoForm, this.countersignForm, this.approvalInfoForm)
+ formDataList = await this.validateFormList(this.processInfoForm, this.countersignForm, this.approvalInfoForm).catch(() => {
+ if (!flag) {
+ flag = base
+ }
+ // 空数组防止后续操作报错
+ return []
+ })
} else {
formDataList = [
this.processInfoForm.getFieldsValue(),
@@ -394,9 +408,9 @@ export default {
this.approvalInfoForm.validateFields(['commitText'], { force: true }, () => {})
}
// 收集人员信息
- const personInfo = this.getPersonInfo(isValidate)
+ const personInfo = this.getPersonInfo(isValidate && !flag)
if (!personInfo) {
- throw new Error('user')
+ flag = user
}
// 开始处理信息
@@ -432,6 +446,11 @@ export default {
// 业务表格数据,用于强制撤回后回显
draftData: params.processEsInspectPlanList
})
+
+ // 如果有校验失败的,那就报错
+ if (flag) {
+ throw new Error(flag)
+ }
return params
},
/**
diff --git a/src/views/workCenter/enterpriseStandardInspectionProcess/EnterpriseStandardInspectionProcess.vue b/src/views/workCenter/enterpriseStandardInspectionProcess/EnterpriseStandardInspectionProcess.vue
index 51ad5c2d..d043fb5b 100644
--- a/src/views/workCenter/enterpriseStandardInspectionProcess/EnterpriseStandardInspectionProcess.vue
+++ b/src/views/workCenter/enterpriseStandardInspectionProcess/EnterpriseStandardInspectionProcess.vue
@@ -305,30 +305,42 @@ export default {
async getPageParams (isValidate = true) {
// 去除备注必填
this.validatorRules.remarks.rules[0].required = false
+ // 报错标记(base基本信息校验失败,user人员信息校验失败)
+ let flag = ''
+ const base = 'base'
+ const user = 'user'
// 如果需要校验校验表格数据
if (isValidate) {
const list = this.$refs.inspectionProcessTable.dataSource
if (list.length === 0) {
this.$message.warning(this.$t('addAtLeastOneRowOfData'))
- throw new Error('base')
+ if (!flag) {
+ flag = base
+ }
}
/**
* 调整为前端存储
*/
// 节点1:稽查内容条数不能为0
if (this.isInitiate && list.some(item => !(item.enterpriseStandardInspectContentList && item.enterpriseStandardInspectContentList.length))) {
- this.$message.warning(this.$t('pleaseCompleteTableInfo'))
- throw new Error('base')
+ this.$message.warning(this.$t('workCenter.esInspectionProcess.pleaseFillInspectionContent'))
+ if (!flag) {
+ flag = base
+ }
}
// 节点3:稽查报告条数不能为0
if (this.isInputInspectionReport && list.some(item => !(item.enterpriseStandardInspectReportList && item.enterpriseStandardInspectReportList.length))) {
- this.$message.warning(this.$t('pleaseCompleteTableInfo'))
- throw new Error('base')
+ this.$message.warning(this.$t('workCenter.esInspectionProcess.pleaseFillInspectionReport'))
+ if (!flag) {
+ flag = base
+ }
}
// 节点3:整改计划条数不能为0
if (this.isInputInspectionReport && list.some(item => !(item.enterpriseStandardInspectRectifyPlanList && item.enterpriseStandardInspectRectifyPlanList.length))) {
- this.$message.warning(this.$t('pleaseCompleteTableInfo'))
- throw new Error('base')
+ this.$message.warning(this.$t('workCenter.esInspectionProcess.pleaseFillRectificationPlan'))
+ if (!flag) {
+ flag = base
+ }
}
}
const params = {}
@@ -354,7 +366,13 @@ export default {
// 收集所有表单信息
let formDataList = []
if (isValidate) {
- formDataList = await this.validateFormList(this.processInfoForm, this.approvalInfoForm)
+ formDataList = await this.validateFormList(this.processInfoForm, this.approvalInfoForm).catch(() => {
+ if (!flag) {
+ flag = base
+ }
+ // 空数组防止后续操作报错
+ return []
+ })
} else {
formDataList = [
this.processInfoForm.getFieldsValue(),
@@ -364,9 +382,9 @@ export default {
this.approvalInfoForm.validateFields(['commitText'], { force: true }, () => {})
}
// 收集人员信息
- const personInfo = this.getPersonInfo(isValidate)
+ const personInfo = this.getPersonInfo(isValidate && !flag)
if (!personInfo) {
- throw new Error('user')
+ flag = user
}
// 开始处理信息
@@ -393,6 +411,11 @@ export default {
// 业务表格数据,用于强制撤回后回显
draftData: params.processEsInspectList
})
+
+ // 如果有校验失败的,那就报错
+ if (flag) {
+ throw new Error(flag)
+ }
return params
},
/**
diff --git a/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessContent.vue b/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessContent.vue
index a21b223d..e93e21ef 100644
--- a/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessContent.vue
+++ b/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessContent.vue
@@ -5,7 +5,6 @@
:visible="visible"
:confirmLoading="loading"
switchFullscreen
- @ok="handleOk"
@cancel="handleCancel"
:cancelText="$t('close')">
@@ -39,6 +38,17 @@
+
+
+
+
+ {{ $t('cancel') }}
+
+
+ {{ $t('submit') }}
+
+
+
@@ -85,7 +95,6 @@ export default {
// },
{
// 操作
- fixed: 'right',
title: this.$t('operation'),
// dataIndex: 'action',
align: 'center',
@@ -107,7 +116,7 @@ export default {
index: -1,
// 需要删除的数据id(前端添加后没有保存表的数据没有id)
delIds: [],
- columns: columns.slice(0, this.disabled ? 3 : 4)
+ columns: columns.slice(0, this.disabled ? 2 : 3)
}
},
methods: {
diff --git a/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessRectificationPlan.vue b/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessRectificationPlan.vue
index 287a5be4..4658c309 100644
--- a/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessRectificationPlan.vue
+++ b/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessRectificationPlan.vue
@@ -5,7 +5,6 @@
:visible="visible"
:confirmLoading="loading"
switchFullscreen
- @ok="handleOk"
@cancel="handleCancel"
:cancelText="$t('close')">
@@ -47,6 +46,15 @@
+
+
+
+ {{ $t('cancel') }}
+
+
+ {{ $t('submit') }}
+
+
diff --git a/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessReport.vue b/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessReport.vue
index 39fbe94c..d8415fc8 100644
--- a/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessReport.vue
+++ b/src/views/workCenter/enterpriseStandardInspectionProcess/modules/InspectionProcessReport.vue
@@ -5,7 +5,6 @@
:visible="visible"
:confirmLoading="confirmLoading"
switchFullscreen
- @ok="handleOk"
@cancel="handleCancel"
:cancelText="$t('close')">
@@ -44,6 +43,15 @@
+
+
+
+ {{ $t('cancel') }}
+
+
+ {{ $t('submit') }}
+
+
diff --git a/src/views/workCenter/enterpriseStandardInspectionRectification/EnterpriseStandardInspectionRectification.vue b/src/views/workCenter/enterpriseStandardInspectionRectification/EnterpriseStandardInspectionRectification.vue
index 6788839e..639b5043 100644
--- a/src/views/workCenter/enterpriseStandardInspectionRectification/EnterpriseStandardInspectionRectification.vue
+++ b/src/views/workCenter/enterpriseStandardInspectionRectification/EnterpriseStandardInspectionRectification.vue
@@ -303,12 +303,26 @@ export default {
async getPageParams (isValidate = true) {
// 去除备注必填
this.validatorRules.remarks.rules[0].required = false
+ // 报错标记(base基本信息校验失败,user人员信息校验失败)
+ let flag = ''
+ const base = 'base'
+ const user = 'user'
const params = {}
// 收集所有表单信息
let formDataList = []
if (isValidate) {
- formDataList = await this.validateFormList(this.processInfoForm, this.approvalInfoForm)
- formDataList[2] = await this.$refs.baseInfoForm.getDataValidate()
+ formDataList = await this.validateFormList(this.processInfoForm, this.approvalInfoForm).catch(() => {
+ if (!flag) {
+ flag = base
+ }
+ // 设置成数组防止后面报错
+ return []
+ })
+ formDataList[2] = await this.$refs.baseInfoForm.getDataValidate().catch(() => {
+ if (!flag) {
+ flag = base
+ }
+ })
} else {
formDataList = [
this.processInfoForm.getFieldsValue(),
@@ -319,9 +333,9 @@ export default {
this.approvalInfoForm.validateFields(['commitText'], { force: true }, () => {})
}
// 收集人员信息
- const personInfo = this.getPersonInfo(isValidate)
+ const personInfo = this.getPersonInfo(isValidate && !flag)
if (!personInfo) {
- throw new Error('user')
+ flag = user
}
// 自动发起特殊流程,单独把人员信息存一份
@@ -361,6 +375,11 @@ export default {
// 业务表格数据,用于强制撤回后回显
draftData: params.processEsInspectRectify
})
+
+ // 如果有校验失败的,那就报错
+ if (flag) {
+ throw new Error(flag)
+ }
return params
},
/**
diff --git a/src/views/workCenter/inspectionExtensionRequestProcess/InspectionExtensionRequestProcess.vue b/src/views/workCenter/inspectionExtensionRequestProcess/InspectionExtensionRequestProcess.vue
index 01fb79ac..e1d45f52 100644
--- a/src/views/workCenter/inspectionExtensionRequestProcess/InspectionExtensionRequestProcess.vue
+++ b/src/views/workCenter/inspectionExtensionRequestProcess/InspectionExtensionRequestProcess.vue
@@ -305,10 +305,16 @@ export default {
async getPageParams (isValidate = true) {
// 去除备注必填
this.validatorRules.remarks.rules[0].required = false
+ // 报错标记(base基本信息校验失败,user人员信息校验失败)
+ let flag = ''
+ const base = 'base'
+ const user = 'user'
// 必须有数据才能提交
if (isValidate && this.$refs.extensionRequestTable.dataSource.length === 0) {
this.$message.warning(this.$t('addAtLeastOneRowOfData'))
- throw new Error('base')
+ if (!flag) {
+ flag = base
+ }
}
const params = {}
// 收集表格信息
@@ -318,7 +324,13 @@ export default {
// 收集所有表单信息
let formDataList = []
if (isValidate) {
- formDataList = await this.validateFormList(this.processInfoForm, this.approvalInfoForm)
+ formDataList = await this.validateFormList(this.processInfoForm, this.approvalInfoForm).catch(() => {
+ if (!flag) {
+ flag = base
+ }
+ // 设置成数组防止后面报错
+ return []
+ })
} else {
formDataList = [
this.processInfoForm.getFieldsValue(),
@@ -328,9 +340,9 @@ export default {
this.approvalInfoForm.validateFields(['commitText'], { force: true }, () => {})
}
// 收集人员信息
- const personInfo = this.getPersonInfo(isValidate)
+ const personInfo = this.getPersonInfo(isValidate && !flag)
if (!personInfo) {
- throw new Error('user')
+ flag = user
}
// 开始处理信息
@@ -357,6 +369,11 @@ export default {
// 业务表格数据,用于强制撤回后回显
draftData: params.processEsInspectDelayApplyList
})
+
+ // 如果有校验失败的,那就报错
+ if (flag) {
+ throw new Error(flag)
+ }
return params
},
/**
diff --git a/src/views/workCenter/permissionApplicationProcess/PermissionApplicationProcess.vue b/src/views/workCenter/permissionApplicationProcess/PermissionApplicationProcess.vue
index 2e7110e7..4cfaeb68 100644
--- a/src/views/workCenter/permissionApplicationProcess/PermissionApplicationProcess.vue
+++ b/src/views/workCenter/permissionApplicationProcess/PermissionApplicationProcess.vue
@@ -408,14 +408,22 @@ export default {
async getPageParams (isValidate = true) {
// 去除备注必填
this.validatorRules.remarks.rules[0].required = false
+ // 报错标记(base基本信息校验失败,user人员信息校验失败)
+ let flag = ''
+ const base = 'base'
+ const user = 'user'
// 节点1判断表格是否有数据
if (this.isInitiate && this.$refs.baseInfoTable.dataSource.length === 0) {
this.$message.warning(this.$t('addAtLeastOneRowOfData'))
- throw new Error('base')
+ if (!flag) {
+ flag = base
+ }
} else if (!this.isInitiate && this.$refs.applyPermissionTable.dataSource.length === 0) {
// 其他节点判断表单中的表格是否有数据
this.$message.warning(this.$t('addAtLeastOneRowOfData'))
- throw new Error('base')
+ if (!flag) {
+ flag = base
+ }
}
// 校验表格中是否已有权限
if (isValidate && this.isInitiate) {
@@ -423,7 +431,9 @@ export default {
await checkPermissionApply({ ids }).then(res => {
if (!res.success) {
this.$message.warning(res.message)
- throw new Error('base')
+ if (!flag) {
+ flag = base
+ }
}
})
}
@@ -431,16 +441,13 @@ export default {
// 收集所有表单信息
let formDataList = []
if (isValidate) {
- // 记录表单验证是否报错
- let err = null
formDataList = await this.validateFormList(this.processInfoForm, this.approvalInfoForm, this.baseInfoForm).catch(() => {
- err = true
+ if (!flag) {
+ flag = base
+ }
+ // 设置成数组防止后面报错
return []
})
- // 如果有错误就跳转表单
- if (err !== null) {
- throw new Error('base')
- }
} else {
formDataList = [
this.processInfoForm.getFieldsValue(),
@@ -451,9 +458,9 @@ export default {
this.approvalInfoForm.validateFields(['commitText'], { force: true }, () => {})
}
// 收集人员信息
- const personInfo = this.getPersonInfo(isValidate)
+ const personInfo = this.getPersonInfo(isValidate && !flag)
if (!personInfo) {
- throw new Error('user')
+ flag = user
}
// 开始处理信息
@@ -491,6 +498,11 @@ export default {
// 业务数据,用于强制撤回后回显
draftData: params.processEsPermissionApply
})
+
+ // 如果有校验失败的,那就报错
+ if (flag) {
+ throw new Error(flag)
+ }
return params
},
/**
diff --git a/src/views/workCenter/postMeetingManageProcess/PostMeetingManageProcess.vue b/src/views/workCenter/postMeetingManageProcess/PostMeetingManageProcess.vue
index 28f936e1..9205e3ae 100644
--- a/src/views/workCenter/postMeetingManageProcess/PostMeetingManageProcess.vue
+++ b/src/views/workCenter/postMeetingManageProcess/PostMeetingManageProcess.vue
@@ -329,23 +329,26 @@ export default {
async getPageParams (isValidate = true) {
// 去除备注必填
this.validatorRules.remarks.rules[0].required = false
+ // 报错标记(base基本信息校验失败,user人员信息校验失败)
+ let flag = ''
+ const base = 'base'
+ const user = 'user'
const params = {}
// 收集所有表单信息
let formDataList = []
if (isValidate) {
- // 记录表单验证是否报错
- let err = null
formDataList = await this.validateFormList(this.processInfoForm, this.approvalInfoForm).catch(() => {
- err = true
+ if (!flag) {
+ flag = base
+ }
+ // 设置成数组防止后面报错
return []
})
formDataList[2] = await this.$refs.baseInfoForm.getDataValidate().catch(() => {
- err = true
+ if (!flag) {
+ flag = base
+ }
})
- // 如果有错误就跳转表单
- if (err !== null) {
- throw new Error('base')
- }
} else {
formDataList = [
this.processInfoForm.getFieldsValue(),
@@ -357,9 +360,9 @@ export default {
}
// 收集人员信息
- const personInfo = this.getPersonInfo(isValidate)
+ const personInfo = this.getPersonInfo(isValidate && !flag)
if (!personInfo) {
- throw new Error('user')
+ flag = user
}
// 开始处理信息
@@ -397,6 +400,11 @@ export default {
// 业务数据,用于强制撤回后回显
draftData: params.processMeetingManage
})
+
+ // 如果有校验失败的,那就报错
+ if (flag) {
+ throw new Error(flag)
+ }
return params
},
/**
diff --git a/src/views/workCenter/standardPromotionProcess/modules/BaseInfoForm.vue b/src/views/workCenter/standardPromotionProcess/modules/BaseInfoForm.vue
index 9b129f64..6fd80d3c 100644
--- a/src/views/workCenter/standardPromotionProcess/modules/BaseInfoForm.vue
+++ b/src/views/workCenter/standardPromotionProcess/modules/BaseInfoForm.vue
@@ -354,6 +354,10 @@ export default {
this.disabledInitiator = val ? !!ids : true
this.initiatorName = names
this.$set(this.formInline, 'initiator', ids)
+ // 如果接口有回显,就去掉校验信息
+ if (ids) {
+ this.$refs.ruleForm.clearValidate('initiator')
+ }
}
})
}