From b32150d1fd576fa3b89e85e2f99be2edc67b9293 Mon Sep 17 00:00:00 2001 From: xiangpei <xiangpei@timesnew.cn> Date: 星期二, 17 九月 2024 16:26:15 +0800 Subject: [PATCH] 工单详情页优化 --- src/views/system/work-order/detail/index.vue | 32 ++++++++++++++++++++++++++++---- 1 files changed, 28 insertions(+), 4 deletions(-) diff --git a/src/views/system/work-order/detail/index.vue b/src/views/system/work-order/detail/index.vue index f2b66fd..88a65cb 100644 --- a/src/views/system/work-order/detail/index.vue +++ b/src/views/system/work-order/detail/index.vue @@ -65,10 +65,10 @@ </div> <div style="margin-left: 2px">鏄惁鎶ュ</div> </div> - <div class="warp"> + <div class="warp" style="display: flex;flex-direction: row;align-items: center"> <div v-if="workOrderInfo.hasReport"><el-link @click type="primary">{{workOrderInfo.hasReport ? '宸叉姤澶�' : '鏈姤澶�'}}</el-link></div> <div v-else>{{workOrderInfo.hasReport ? '宸叉姤澶�' : '鏈姤澶�'}}</div> - <div v-if="!workOrderInfo.hasReport"><el-link type="primary">浜嬪悗鎶ュ</el-link></div> + <div v-if="!workOrderInfo.hasReport"><el-link type="primary">(浜嬪悗鎶ュ)</el-link></div> </div> </div> <div class="info-item weight4"> @@ -78,7 +78,12 @@ </div> <div style="margin-left: 2px">澶勭悊缁撴灉</div> </div> - <div class="warp">{{covertStatus(workOrderInfo.status)}}</div> + <div class="warp" style="display: flex;flex-direction: row;align-items: center"> + <div>{{covertStatus(workOrderInfo.status)}}</div> + <div v-if="workOrderInfo.status ==='YW_HANDLE'"> + <el-link type="primary" @click="handleAuditing">(瀹℃牳)</el-link> + </div> + </div> </div> </div> </el-tab-pane> @@ -159,16 +164,24 @@ <div style="margin-top: 8px">{{img.createTime}}</div> </div> </div> + + <WorkOrderAuditing :auditingOpen="auditingOpen" :dataForm="auditingForm" :ywConditions="ywConditions" @close="closeAuditing"/> + </div> </template> <script> -import {getWorkOrderInfo, getYwConditionList, getYwAuditingList} from '@/api/platform/work-order' +import {getWorkOrderInfo, getYwConditionList, getYwAuditingList, getYwCondition, listWorkOrder} from '@/api/platform/work-order' import {getReportByGb} from '@/api/platform/report' +import WorkOrderAuditing from "@/components/WorkOrder/WorkOrderAuditing"; export default { name: "index", + components: {WorkOrderAuditing}, data() { return { + ywConditions: [], + auditingOpen: false, + auditingForm: {}, selectedTab: 'workorder', loading1: false, loading2: false, @@ -200,6 +213,17 @@ this.getWorkOrder() }, methods: { + closeAuditing() { + this.auditingOpen = false + }, + // 瀹℃牳鎸夐挳 + handleAuditing() { + this.auditingForm = this.workOrderInfo + getYwCondition(this.workOrderInfo.workOrderNo).then(response => { + this.ywConditions = response.data + this.auditingOpen = true + }) + }, getImgUrl(path) { return this.$img + path; }, -- Gitblit v1.8.0