fix 79554

This commit is contained in:
danshihao
2023-12-22 16:48:30 +08:00
parent 370b6abef6
commit d9311dbb7e
2 changed files with 75 additions and 15 deletions
@@ -251,11 +251,18 @@ export default {
// 去除备注必填
this.validatorRules.remarks.rules[0].required = false
const params = {}
// 记录验证是否报错
let err = null
// 收集所有表单信息
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(() => {
err = 'base'
return []
})
formDataList[2] = await this.$refs.baseInfoForm.getDataValidate().catch(() => {
err = 'base'
})
} else {
formDataList = [
this.processInfoForm.getFieldsValue(),
@@ -287,7 +294,10 @@ export default {
projectId: this.projectId,
id: this.formInfo.id
})
// 如果有错误就跳转对应页面
if (err !== null) {
throw new Error(err)
}
return params
},
/**