From 533e07bd59fc7e66b7c725b763b99423bed761f1 Mon Sep 17 00:00:00 2001 From: lideqin <694785430@qq.com> Date: Thu, 18 Jul 2024 14:32:14 +0800 Subject: [PATCH] =?UTF-8?q?[update]=20=E6=B3=95=E8=A7=84=E7=AC=A6=E5=90=88?= =?UTF-8?q?=E6=80=A7=E8=AF=84=E4=BC=B0=E5=BA=93?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../RegulatoryComplianceCheckProcess.vue | 7 +- .../modules/DesignEngineerEvaluation.vue | 24 ++- .../modules/EngineerInitBaseInfo.vue | 2 +- .../modules/FinishAuditBaseInfo.vue | 4 +- .../InterfacePersonDeliveryBaseInfo.vue | 2 +- .../modules/MainFinderCollectBaseInfo.vue | 7 +- .../modules/MainFinderCollectEditModal.vue | 163 +++++++++++------- .../modules/MainFinderDistributesBaseInfo.vue | 54 +++++- .../modules/MainFinderSingleAuditBaseInfo.vue | 4 +- .../MainFinderTwiceDistributesBaseInfo.vue | 2 +- 10 files changed, 179 insertions(+), 90 deletions(-) diff --git a/src/views/workCenter/regulatoryComplianceCheckProcess/RegulatoryComplianceCheckProcess.vue b/src/views/workCenter/regulatoryComplianceCheckProcess/RegulatoryComplianceCheckProcess.vue index 63bf0c6..40dcef1 100644 --- a/src/views/workCenter/regulatoryComplianceCheckProcess/RegulatoryComplianceCheckProcess.vue +++ b/src/views/workCenter/regulatoryComplianceCheckProcess/RegulatoryComplianceCheckProcess.vue @@ -205,12 +205,11 @@ import UserSelectModal from '@/components/selection/UserSelectModal' import { WorkCenterMixin } from '@/mixins/WorkCenterMixin' import { RegulatoryComplianceCheckNodes, ProcessKey, ProcessType } from '../../../enums/commonEnums' import { - getDataDraft, getLookData, processAddSign, processSave, + getDataDraft, getLookData, processAddSign, processSave, processTransfer, regulatoryComplianceCheckAgree, regulatoryComplianceCheckApproval, regulatoryComplianceCheckGetDataById, regulatoryComplianceCheckReject, - regulatoryComplianceCheckSubmit, - regulatoryComplianceCheckTurnTo + regulatoryComplianceCheckSubmit } from '../../../api/workCenter' import pick from 'lodash.pick' import EngineerInitBaseInfo from './modules/EngineerInitBaseInfo' @@ -612,7 +611,7 @@ export default { const param = Object.assign({}, values) param.userId = userIds param.taskId = this.$route.query.taskId - regulatoryComplianceCheckTurnTo(param).then(res => { + processTransfer(param).then(res => { if (res.success) { this.$message.success(res.message) this.goBack() diff --git a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/DesignEngineerEvaluation.vue b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/DesignEngineerEvaluation.vue index 22efed8..4c1544d 100644 --- a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/DesignEngineerEvaluation.vue +++ b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/DesignEngineerEvaluation.vue @@ -20,6 +20,7 @@ style="width: 100%" :placeholder="$t('pleaseSelect')" dict-code="evaluation_result" + @change="resultChange(record)" v-model="record.result"> @@ -90,7 +91,7 @@ export default { title: this.$t('modelStatus'), align: 'center', width: 180, - dataIndex: 'modelState_dictText', + dataIndex: 'modelStatus_dictText', scopedSlots: { customRender: 'text' } }, { // 评价结果 @@ -126,7 +127,7 @@ export default { 2: { // 不符合 rules: { // 整改周期 - correctionCycle: { required: true, message: this.$t('pleaseSelect') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' }, + correctionPeriod: { required: true, message: this.$t('pleaseSelect') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' }, // 整改费用 correctionCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'), trigger: 'blur' }, // 共用后本项目所需费用 @@ -143,7 +144,7 @@ export default { fieldShowType: 5, dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), fieldMustInput: true, - dbFieldName: 'correctionCycle', + dbFieldName: 'correctionPeriod', dictCode: 'correction_period' }, { // 整改费用 @@ -201,7 +202,7 @@ export default { 4: { // 待验证 rules: { // 整改周期 - correctionCycle: { required: true, message: this.$t('pleaseSelect') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' }, + correctionPeriod: { required: true, message: this.$t('pleaseSelect') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' }, // 整改费用 correctionCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'), trigger: 'blur' }, // 共用后本项目所需费用 @@ -218,7 +219,7 @@ export default { fieldShowType: 5, dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), fieldMustInput: true, - dbFieldName: 'correctionCycle', + dbFieldName: 'correctionPeriod', dictCode: 'correction_period' }, { // 整改费用 @@ -286,6 +287,19 @@ export default { } return data }, + // 评估结果改变,清空备注和佐证材料,不满足要求的现状,整改方案,整改周期,整改费用,与其他项目共用性,共用后本项目所需费用 + resultChange (record) { + const index = this.dataSource.findIndex(item => item.id === record.id) + this.dataSource[index].remark = '' + this.dataSource[index].material = '' + this.dataSource[index].unsatisfiedRequire = '' + this.dataSource[index].correctionSolution = '' + this.dataSource[index].correctionPeriod = null + this.dataSource[index].correctionPeriod_dictText = '' + this.dataSource[index].correctionCost = '' + this.dataSource[index].commonality = '' + this.dataSource[index].commonalityCost = '' + }, handleTableChange (pagination) { this.ipagination = pagination } diff --git a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/EngineerInitBaseInfo.vue b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/EngineerInitBaseInfo.vue index dc5f219..9717378 100644 --- a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/EngineerInitBaseInfo.vue +++ b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/EngineerInitBaseInfo.vue @@ -418,7 +418,7 @@ export default { title: this.$t('workCenter.regulatoryComplianceCheckProcess.modelStatus'), align: 'center', width: 180, - dataIndex: 'modelState_dictText', + dataIndex: 'modelStatus_dictText', scopedSlots: { customRender: 'text' } }, { // 责任部门 diff --git a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/FinishAuditBaseInfo.vue b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/FinishAuditBaseInfo.vue index b593c87..1e61c89 100644 --- a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/FinishAuditBaseInfo.vue +++ b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/FinishAuditBaseInfo.vue @@ -86,7 +86,7 @@ export default { title: this.$t('modelStatus'), align: 'center', width: 180, - dataIndex: 'modelState_dictText', + dataIndex: 'modelStatus_dictText', scopedSlots: { customRender: 'text' } }, { // 责任部门 @@ -128,7 +128,7 @@ export default { title: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), align: 'center', width: 180, - dataIndex: 'correctionCycle_dictText', + dataIndex: 'correctionPeriod_dictText', scopedSlots: { customRender: 'text' } }, { // 整改费用 diff --git a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/InterfacePersonDeliveryBaseInfo.vue b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/InterfacePersonDeliveryBaseInfo.vue index e2f4796..810a866 100644 --- a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/InterfacePersonDeliveryBaseInfo.vue +++ b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/InterfacePersonDeliveryBaseInfo.vue @@ -126,7 +126,7 @@ export default { title: this.$t('workCenter.regulatoryComplianceCheckProcess.modelStatus'), align: 'center', width: 180, - dataIndex: 'modelState_dictText', + dataIndex: 'modelStatus_dictText', scopedSlots: { customRender: 'text' } } ], diff --git a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderCollectBaseInfo.vue b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderCollectBaseInfo.vue index f9cadeb..b610aa3 100644 --- a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderCollectBaseInfo.vue +++ b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderCollectBaseInfo.vue @@ -166,7 +166,7 @@ export default { title: this.$t('modelStatus'), align: 'center', width: 180, - dataIndex: 'modelState_dictText', + dataIndex: 'modelStatus_dictText', scopedSlots: { customRender: 'text' } }, { // 责任部门 @@ -208,7 +208,7 @@ export default { title: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), align: 'center', width: 180, - dataIndex: 'correctionCycle_dictText', + dataIndex: 'correctionPeriod_dictText', scopedSlots: { customRender: 'text' } }, { // 整改费用 @@ -374,7 +374,8 @@ export default { // 编辑完成 editOk (result) { const index = this.dataSource.findIndex(item => item.id === result.id) - this.dataSource[index] = Object.assign({}, this.dataSource[index], result) + this.dataSource[index] = Object.assign({}, result) + this.$forceUpdate() } } } diff --git a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderCollectEditModal.vue b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderCollectEditModal.vue index 82f897a..3f6fd85 100644 --- a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderCollectEditModal.vue +++ b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderCollectEditModal.vue @@ -9,86 +9,98 @@ @ok="handleOk" @cancel="handleCancel"> - + + v-decorator="['assessor', validatorRules.assessor]" /> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + - diff --git a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderDistributesBaseInfo.vue b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderDistributesBaseInfo.vue index 11312b6..2a38260 100644 --- a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderDistributesBaseInfo.vue +++ b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderDistributesBaseInfo.vue @@ -18,6 +18,7 @@ :placeholder="$t('pleaseSelect') + this.$t('workCenter.regulatoryComplianceCheckProcess.checkWhetherTheTaskIsDelivered')" dict-code="yn" v-model="formInline.distributeFlag" + :disabled="formInline.lockDistributeFlag" @change="distributeFlagChange"> @@ -84,6 +85,7 @@ style="width: 100%" :placeholder="$t('pleaseSelect')" dict-code="evaluation_result" + @change="resultChange(record)" v-model="record.result"> @@ -288,7 +290,7 @@ export default { title: this.$t('modelStatus'), align: 'center', width: 180, - dataIndex: 'modelState_dictText', + dataIndex: 'modelStatus_dictText', scopedSlots: { customRender: 'text' } }, { // 设计工程师 @@ -342,7 +344,7 @@ export default { title: this.$t('modelStatus'), align: 'center', width: 180, - dataIndex: 'modelState_dictText', + dataIndex: 'modelStatus_dictText', scopedSlots: { customRender: 'text' } }, { // 评价结果 @@ -378,7 +380,7 @@ export default { 2: { // 不符合 rules: { // 整改周期 - correctionCycle: { required: true, message: this.$t('pleaseSelect') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' }, + correctionPeriod: { required: true, message: this.$t('pleaseSelect') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' }, // 整改费用 correctionCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'), trigger: 'blur' }, // 共用后本项目所需费用 @@ -395,7 +397,7 @@ export default { fieldShowType: 5, dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), fieldMustInput: true, - dbFieldName: 'correctionCycle', + dbFieldName: 'correctionPeriod', dictCode: 'correction_period' }, { // 整改费用 @@ -453,7 +455,7 @@ export default { 4: { // 待验证 rules: { // 整改周期 - correctionCycle: { required: true, message: this.$t('pleaseSelect') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' }, + correctionPeriod: { required: true, message: this.$t('pleaseSelect') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), trigger: 'blur' }, // 整改费用 correctionCost: { required: true, message: this.$t('pleaseEnter') + this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCost'), trigger: 'blur' }, // 共用后本项目所需费用 @@ -470,7 +472,7 @@ export default { fieldShowType: 5, dbFieldTxt: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), fieldMustInput: true, - dbFieldName: 'correctionCycle', + dbFieldName: 'correctionPeriod', dictCode: 'correction_period' }, { // 整改费用 @@ -586,9 +588,32 @@ export default { // 排查任务是否下发改变 distributeFlagChange (value) { if (value === YesOrNoEnum.YES.value) { - this.dataSource = JSON.parse(JSON.stringify(this.dataSourceCopy)) + // 把数据中的备注和佐证材料,不满足要求的现状,整改方案,整改周期,整改费用,与其他项目共用性,共用后本项目所需费用清空 + const arr = this.dataSourceCopy.map(item => { + return { + ...item, + remark: '', + material: '', + unsatisfiedRequire: '', + correctionSolution: '', + correctionPeriod: undefined, + correctionPeriod_dictText: '', + correctionCost: '', + commonality: '', + commonalityCost: '' + } + }) + this.dataSource = JSON.parse(JSON.stringify(arr)) } else { - this.dataSourceEvaluate = JSON.parse(JSON.stringify(this.dataSourceCopy)) + // 把数据中的设计工程师清空 + const arr = this.dataSourceCopy.map(item => { + return { + ...item, + designEngineer: '', + designEngineer_dictText: '' + } + }) + this.dataSourceEvaluate = JSON.parse(JSON.stringify(arr)) } }, // 表格选中 @@ -626,6 +651,19 @@ export default { const dataIndex = this.dataSource.findIndex(item => item.id === fieldName) this.dataSource[dataIndex].designEngineer_dictText = value }, + // 评估结果改变,清空备注和佐证材料,不满足要求的现状,整改方案,整改周期,整改费用,与其他项目共用性,共用后本项目所需费用 + resultChange (record) { + const index = this.dataSourceEvaluate.findIndex(item => item.id === record.id) + this.dataSourceEvaluate[index].remark = '' + this.dataSourceEvaluate[index].material = '' + this.dataSourceEvaluate[index].unsatisfiedRequire = '' + this.dataSourceEvaluate[index].correctionSolution = '' + this.dataSourceEvaluate[index].correctionPeriod = null + this.dataSourceEvaluate[index].correctionPeriod_dictText = '' + this.dataSourceEvaluate[index].correctionCost = '' + this.dataSourceEvaluate[index].commonality = '' + this.dataSourceEvaluate[index].commonalityCost = '' + }, // 导入 handleImportExcel (info) { // 限制导入大于500MB diff --git a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderSingleAuditBaseInfo.vue b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderSingleAuditBaseInfo.vue index ace0ddf..56a9ca6 100644 --- a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderSingleAuditBaseInfo.vue +++ b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderSingleAuditBaseInfo.vue @@ -101,7 +101,7 @@ export default { title: this.$t('modelStatus'), align: 'center', width: 180, - dataIndex: 'modelState_dictText', + dataIndex: 'modelStatus_dictText', scopedSlots: { customRender: 'text' } }, { // 责任部门 @@ -143,7 +143,7 @@ export default { title: this.$t('workCenter.regulatoryComplianceCheckProcess.rectificationCycle'), align: 'center', width: 180, - dataIndex: 'correctionCycle_dictText', + dataIndex: 'correctionPeriod_dictText', scopedSlots: { customRender: 'text' } }, { // 整改费用 diff --git a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderTwiceDistributesBaseInfo.vue b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderTwiceDistributesBaseInfo.vue index f1c5761..8253274 100644 --- a/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderTwiceDistributesBaseInfo.vue +++ b/src/views/workCenter/regulatoryComplianceCheckProcess/modules/MainFinderTwiceDistributesBaseInfo.vue @@ -105,7 +105,7 @@ export default { title: this.$t('modelStatus'), align: 'center', width: 180, - dataIndex: 'modelState_dictText', + dataIndex: 'modelStatus_dictText', scopedSlots: { customRender: 'text' } }, { // 设计工程师