From 03cdb35e648816dfa56fd842292e71341b49eb48 Mon Sep 17 00:00:00 2001 From: danshihao Date: Tue, 19 Dec 2023 10:30:14 +0800 Subject: [PATCH] fix 79311 --- .../EnterpriseStandardInspectionPlanFlow.vue | 27 +++++++++---------- .../EnterpriseStandardInspectionProcess.vue | 20 +++++++------- ...erpriseStandardInspectionRectification.vue | 20 +++++++------- .../InspectionExtensionRequestProcess.vue | 20 +++++++------- .../PermissionApplicationProcess.vue | 20 +++++++------- .../PostMeetingManageProcess.vue | 20 +++++++------- .../StandardPromotionProcess.vue | 6 ++--- 7 files changed, 69 insertions(+), 64 deletions(-) diff --git a/src/views/workCenter/enterpriseStandardInspectionPlan/EnterpriseStandardInspectionPlanFlow.vue b/src/views/workCenter/enterpriseStandardInspectionPlan/EnterpriseStandardInspectionPlanFlow.vue index 4a272f2a..21c5756f 100644 --- a/src/views/workCenter/enterpriseStandardInspectionPlan/EnterpriseStandardInspectionPlanFlow.vue +++ b/src/views/workCenter/enterpriseStandardInspectionPlan/EnterpriseStandardInspectionPlanFlow.vue @@ -228,7 +228,7 @@ export default { // 发起、草稿进来没有nodeId,就默认发起节点 this.currentNode = nodeId || EsInspectionPlan.initiate.value this.currentNodeName = taskName || EsInspectionPlan.initiate.text - this.projectId = projectId + this.projectId = projectId || '' this.btn = EsInspectionPlan.propertyOfValue('btn', this.currentNode) || [] // 如果有nodeId,但是匹配不到任何节点,就是是增加的审批节点 if (nodeId && !EsInspectionPlan.keyOfValue(nodeId)) { @@ -358,8 +358,8 @@ export default { // 处理其他参数 params.map = Object.assign({}, formDataList[1], getPersonInfo) - // 会签表单放到对象最外层单独存储业务信息,params.map里是流程用的 - if (params.map.pass) { + // 节点三:会签表单放到对象最外层单独存储业务信息,params.map里是流程用的 + if (this.currentNode === EsInspectionPlan.liaisonCollect.value && Object.hasOwnProperty.call(params.map, 'pass')) { params.countersignTag = params.map.pass params.map.pass = this.convertPass(params.map.pass) } @@ -460,8 +460,6 @@ export default { this.loading = true this.getPageParams().then(res => { console.log(res) - // 审批意见 - res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value return startInspectPlan(res) }).then(res => { if (res.success) { @@ -484,18 +482,17 @@ export default { if (this.loading) return this.loading = true this.getPageParams().then(res => { - // pass在这里有两种可能 - // 1.联络人汇总节点,选择是否会签,是true,否false; - // 2.其他节点按钮区分,同意传true,驳回传false - if (res.map.pass === undefined) { + // 不是提交按钮 + if (!isSubmitBtn) { + // 不是提交按钮就一直传true 同意 res.map.pass = true + // 没有填写注释,就默认同意 + if (!res.processApprovalRecord.commitText) { + res.processApprovalRecord.commitText = '同意' + } + // 审批意见 + res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value } - // 不是提交按钮 且 如果没有填写注释,就默认同意 - if (!isSubmitBtn && !res.processApprovalRecord.commitText) { - res.processApprovalRecord.commitText = '同意' - } - // 审批意见 - res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value return approvalInspectPlan(res) }).then(res => { if (res.success) { diff --git a/src/views/workCenter/enterpriseStandardInspectionProcess/EnterpriseStandardInspectionProcess.vue b/src/views/workCenter/enterpriseStandardInspectionProcess/EnterpriseStandardInspectionProcess.vue index 71550f3d..af7e9d06 100644 --- a/src/views/workCenter/enterpriseStandardInspectionProcess/EnterpriseStandardInspectionProcess.vue +++ b/src/views/workCenter/enterpriseStandardInspectionProcess/EnterpriseStandardInspectionProcess.vue @@ -193,7 +193,7 @@ export default { // 发起、草稿进来没有nodeId,就默认发起节点 this.currentNode = nodeId || EsInspectionProcess.initiate.value this.currentNodeName = taskName || EsInspectionProcess.initiate.text - this.projectId = projectId + this.projectId = projectId || '' this.btn = EsInspectionProcess.propertyOfValue('btn', this.currentNode) || [] // 如果有nodeId,但是匹配不到任何节点,就是是增加的审批节点 if (nodeId && !EsInspectionProcess.keyOfValue(nodeId)) { @@ -388,8 +388,6 @@ export default { this.loading = true this.getPageParams().then(res => { console.log(res) - // 审批意见 - res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value return startInspectProcess(res) }).then(res => { if (res.success) { @@ -412,13 +410,17 @@ export default { if (this.loading) return this.loading = true this.getPageParams().then(res => { - res.map.pass = true - // 不是提交按钮 且 如果没有填写注释,就默认同意 - if (!isSubmitBtn && !res.processApprovalRecord.commitText) { - res.processApprovalRecord.commitText = '同意' + // 不是提交按钮 + if (!isSubmitBtn) { + // 不是提交按钮就一直传true 同意 + res.map.pass = true + // 没有填写注释,就默认同意 + if (!res.processApprovalRecord.commitText) { + res.processApprovalRecord.commitText = '同意' + } + // 审批意见 + res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value } - // 审批意见 - res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value return approvalInspectProcess(res) }).then(res => { if (res.success) { diff --git a/src/views/workCenter/enterpriseStandardInspectionRectification/EnterpriseStandardInspectionRectification.vue b/src/views/workCenter/enterpriseStandardInspectionRectification/EnterpriseStandardInspectionRectification.vue index a7621690..8e18d853 100644 --- a/src/views/workCenter/enterpriseStandardInspectionRectification/EnterpriseStandardInspectionRectification.vue +++ b/src/views/workCenter/enterpriseStandardInspectionRectification/EnterpriseStandardInspectionRectification.vue @@ -192,7 +192,7 @@ export default { // 自动发起流程: 没有默认节点 this.currentNode = nodeId || '' this.currentNodeName = taskName || '' - this.projectId = projectId + this.projectId = projectId || '' this.btn = EsInspectionRectification.propertyOfValue('btn', this.currentNode) || [] // 如果有nodeId,但是匹配不到任何节点,就是是增加的审批节点 if (nodeId && !EsInspectionRectification.keyOfValue(nodeId)) { @@ -385,8 +385,6 @@ export default { this.getPageParams().then(res => { console.log(res) res.map.pass = true - // 审批意见 - res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value return approvalInspectRectify(res) }).then(res => { if (res.success) { @@ -409,13 +407,17 @@ export default { if (this.loading) return this.loading = true this.getPageParams().then(res => { - res.map.pass = true - // 不是提交按钮 且 如果没有填写注释,就默认同意 - if (!isSubmitBtn && !res.processApprovalRecord.commitText) { - res.processApprovalRecord.commitText = '同意' + // 不是提交按钮 + if (!isSubmitBtn) { + // 不是提交按钮就一直传true 同意 + res.map.pass = true + // 没有填写注释,就默认同意 + if (!res.processApprovalRecord.commitText) { + res.processApprovalRecord.commitText = '同意' + } + // 审批意见 + res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value } - // 审批意见 - res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value return approvalInspectRectify(res) }).then(res => { if (res.success) { diff --git a/src/views/workCenter/inspectionExtensionRequestProcess/InspectionExtensionRequestProcess.vue b/src/views/workCenter/inspectionExtensionRequestProcess/InspectionExtensionRequestProcess.vue index f6032677..27e36f3b 100644 --- a/src/views/workCenter/inspectionExtensionRequestProcess/InspectionExtensionRequestProcess.vue +++ b/src/views/workCenter/inspectionExtensionRequestProcess/InspectionExtensionRequestProcess.vue @@ -196,7 +196,7 @@ export default { // 发起、草稿进来没有nodeId,就默认发起节点 this.currentNode = nodeId || InspectionExtensionRequestProcess.initiate.value this.currentNodeName = taskName || InspectionExtensionRequestProcess.initiate.text - this.projectId = projectId + this.projectId = projectId || '' this.btn = InspectionExtensionRequestProcess.propertyOfValue('btn', this.currentNode) || [] // 如果有nodeId,但是匹配不到任何节点,就是是增加的审批节点 if (nodeId && !InspectionExtensionRequestProcess.keyOfValue(nodeId)) { @@ -393,8 +393,6 @@ export default { this.loading = true this.getPageParams().then(res => { console.log(res) - // 审批意见 - res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value return startInspectExtension(res) }).then(res => { if (res.success) { @@ -417,13 +415,17 @@ export default { if (this.loading) return this.loading = true this.getPageParams().then(res => { - res.map.pass = true - // 不是提交按钮 且 如果没有填写注释,就默认同意 - if (!isSubmitBtn && !res.processApprovalRecord.commitText) { - res.processApprovalRecord.commitText = '同意' + // 不是提交按钮 + if (!isSubmitBtn) { + // 不是提交按钮就一直传true 同意 + res.map.pass = true + // 没有填写注释,就默认同意 + if (!res.processApprovalRecord.commitText) { + res.processApprovalRecord.commitText = '同意' + } + // 审批意见 + res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value } - // 审批意见 - res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value return approvalInspectExtension(res) }).then(res => { if (res.success) { diff --git a/src/views/workCenter/permissionApplicationProcess/PermissionApplicationProcess.vue b/src/views/workCenter/permissionApplicationProcess/PermissionApplicationProcess.vue index 741ca5be..2225b102 100644 --- a/src/views/workCenter/permissionApplicationProcess/PermissionApplicationProcess.vue +++ b/src/views/workCenter/permissionApplicationProcess/PermissionApplicationProcess.vue @@ -253,7 +253,7 @@ export default { // 发起、草稿进来没有nodeId,就默认发起节点 this.currentNode = nodeId || PermissionApply.initiate.value this.currentNodeName = taskName || PermissionApply.initiate.text - this.projectId = projectId + this.projectId = projectId || '' this.btn = PermissionApply.propertyOfValue('btn', this.currentNode) || [] // 如果有nodeId,但是匹配不到任何节点,就是是增加的审批节点 if (nodeId && !PermissionApply.keyOfValue(nodeId)) { @@ -476,8 +476,6 @@ export default { this.loading = true this.getPageParams().then(res => { console.log(res) - // 审批意见 - res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value return startPermissionApply(res) }).then(res => { if (res.success) { @@ -501,13 +499,17 @@ export default { if (this.loading) return this.loading = true this.getPageParams().then(res => { - res.map.pass = true - // 不是提交按钮 且 如果没有填写注释,就默认同意 - if (!isSubmitBtn && !res.processApprovalRecord.commitText) { - res.processApprovalRecord.commitText = '同意' + // 不是提交按钮 + if (!isSubmitBtn) { + // 不是提交按钮就一直传true 同意 + res.map.pass = true + // 没有填写注释,就默认同意 + if (!res.processApprovalRecord.commitText) { + res.processApprovalRecord.commitText = '同意' + } + // 审批意见 + res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value } - // 审批意见 - res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value return approvalPermissionApply(res) }).then(res => { if (res.success) { diff --git a/src/views/workCenter/postMeetingManageProcess/PostMeetingManageProcess.vue b/src/views/workCenter/postMeetingManageProcess/PostMeetingManageProcess.vue index c1946a8d..5e44808d 100644 --- a/src/views/workCenter/postMeetingManageProcess/PostMeetingManageProcess.vue +++ b/src/views/workCenter/postMeetingManageProcess/PostMeetingManageProcess.vue @@ -204,7 +204,7 @@ export default { // 发起、草稿进来没有nodeId,就默认发起节点 this.currentNode = nodeId || PostMeetingManage.initiate.value this.currentNodeName = taskName || PostMeetingManage.initiate.text - this.projectId = projectId + this.projectId = projectId || '' this.btn = PostMeetingManage.propertyOfValue('btn', this.currentNode) || [] // 如果有nodeId,但是匹配不到任何节点,就是是增加的审批节点 if (nodeId && !PostMeetingManage.keyOfValue(nodeId)) { @@ -414,8 +414,6 @@ export default { this.loading = true this.getPageParams().then(res => { console.log(res) - // 审批意见 - res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value return startPostMeetingManage(res) }).then(res => { if (res.success) { @@ -438,14 +436,18 @@ export default { if (this.loading) return this.loading = true this.getPageParams().then(res => { - res.map.pass = true res.notAttend = false - // 不是提交按钮 且 如果没有填写注释,就默认同意 - if (!isSubmitBtn && !res.processApprovalRecord.commitText) { - res.processApprovalRecord.commitText = '同意' + // 不是提交按钮 + if (!isSubmitBtn) { + // 不是提交按钮就一直传true 同意 + res.map.pass = true + // 没有填写注释,就默认同意 + if (!res.processApprovalRecord.commitText) { + res.processApprovalRecord.commitText = '同意' + } + // 审批意见 + res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value } - // 审批意见 - res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value return approvalPostMeetingManage(res) }).then(res => { if (res.success) { diff --git a/src/views/workCenter/standardPromotionProcess/StandardPromotionProcess.vue b/src/views/workCenter/standardPromotionProcess/StandardPromotionProcess.vue index dcc15758..e60133eb 100644 --- a/src/views/workCenter/standardPromotionProcess/StandardPromotionProcess.vue +++ b/src/views/workCenter/standardPromotionProcess/StandardPromotionProcess.vue @@ -75,7 +75,7 @@ import '@assets/less/common.less' import InternalDetailPage from '@comp/InternalDetailPage' import BaseInfoForm from '@views/workCenter/standardPromotionProcess/modules/BaseInfoForm' -import { ApprovalOpinions, ProcessKey, StandardPromotion } from '@/enums/commonEnums' +import { ProcessKey, StandardPromotion } from '@/enums/commonEnums' import { getStandardPromotionDataById, getStandardPromotionDetail, getStandardPromotionProjectId, @@ -174,7 +174,7 @@ export default { // 发起、草稿进来没有nodeId,就默认发起节点 this.currentNode = nodeId || StandardPromotion.initiate.value this.currentNodeName = taskName || StandardPromotion.initiate.text - this.projectId = projectId + this.projectId = projectId || '' this.btn = StandardPromotion.propertyOfValue('btn', this.currentNode) || [] // 如果有nodeId,但是匹配不到任何节点,就是是增加的审批节点 if (nodeId && !StandardPromotion.keyOfValue(nodeId)) { @@ -318,8 +318,6 @@ export default { this.loading = true this.getPageParams().then(res => { console.log(res) - // 审批意见 - res.processApprovalRecord.commitFlag = ApprovalOpinions.AGREE.value return startStandardPromotion(res) }).then(res => { if (res.success) {