From e728c55c65d943ad90a6cf6e1c619003b4c9a077 Mon Sep 17 00:00:00 2001 From: gaoluyang <2820782392@qq.com> Date: 星期六, 29 三月 2025 17:52:26 +0800 Subject: [PATCH] 质量监控、监督计划-流程修改 --- src/views/CNAS/process/ensureResults/qualityControlPlan/components/rectifyDialogNew.vue | 25 +++++++++++++++++-------- 1 files changed, 17 insertions(+), 8 deletions(-) diff --git a/src/views/CNAS/process/ensureResults/qualityControlPlan/components/rectifyDialogNew.vue b/src/views/CNAS/process/ensureResults/qualityControlPlan/components/rectifyDialogNew.vue index b3838eb..344497c 100644 --- a/src/views/CNAS/process/ensureResults/qualityControlPlan/components/rectifyDialogNew.vue +++ b/src/views/CNAS/process/ensureResults/qualityControlPlan/components/rectifyDialogNew.vue @@ -242,9 +242,9 @@ </div> <span slot="footer" class="dialog-footer"> <el-button @click="closeRectifyDia">鍙� 娑�</el-button> - <el-button v-if="currentStep === 0" :loading="editLoad" type="primary" @click="handleEdit">鎻� 浜�</el-button> - <el-button v-if="currentStep === 1" :loading="editLoad" @click="handleEdit(0)">涓嶉�氳繃</el-button> - <el-button v-if="currentStep === 1" :loading="editLoad" type="primary" @click="handleEdit(1)">閫� + <el-button v-if="currentStep === 0 && userId == supervisedUserId" :loading="editLoad" type="primary" @click="handleEdit">鎻� 浜�</el-button> + <el-button v-if="currentStep === 1 && userId == approverUserId" :loading="editLoad" @click="handleEdit(0)">涓嶉�氳繃</el-button> + <el-button v-if="currentStep === 1 && userId == approverUserId" :loading="editLoad" type="primary" @click="handleEdit(1)">閫� 杩�</el-button> </span> </el-dialog> @@ -258,6 +258,7 @@ } from "@/api/cnas/process/ensureResults/qualitySupervise"; import {selectUserCondition} from "@/api/business/inspectionTask"; import {getThisYearTrainingDetailed} from "@/api/cnas/systemManagement/correctiveAction"; +import {mapGetters} from "vuex"; export default { name: 'rectifyDialog', @@ -298,7 +299,12 @@ editLoad: false, personList: [], yearTrainingDetailed: [], + supervisedUserId: '', + approverUserId: '' }; + }, + computed: { + ...mapGetters(["userId"]), }, // 鏂规硶闆嗗悎 methods: { @@ -307,6 +313,7 @@ this.searchInfo(row) this.form.superviseDetailsId = row.superviseDetailsId this.form.approveId = row.approveId + this.supervisedUserId = row.supervisedUserId this.getAuthorizedPerson() // 鑾峰彇浜哄憳鍒楄〃 this.getYearTrainingDetailed() // 鑾峰彇鍩硅璁″垝 }, @@ -314,16 +321,18 @@ searchInfo (row) { this.form.qualityMonitorDetailsId = row.qualityMonitorDetailsId getSuperviseDetailCorrect({superviseDetailsId: row.superviseDetailsId}).then(res => { - if (!res.data.approverUserId) { - this.currentStep = 0 - } else { - if (res.data.isFinish === 0) { + if (res.data.approverUserId) { + // 鏄惁缁撴潫0:鏈粨鏉�, 1:宸茬粨鏉� + if (res.data.isFinish != 1) { this.currentStep = 1 - } else { + } else if (res.data.isFinish == 1) { this.currentStep = 2 } + } else { + this.currentStep = 0 } this.form = res.data + this.approverUserId = res.data.approverUserId }).catch(err => { console.log('err---', err); }) -- Gitblit v1.9.3