From 1cb38dbdb58bc3966453ca43585140323e50d1b8 Mon Sep 17 00:00:00 2001 From: zhaowei <zhaowei> Date: 星期三, 20 八月 2025 09:15:51 +0800 Subject: [PATCH] 1、二、三保工单增加批量打印及导出完工单和验收单功能 2、二保工单审批流程图展示增加滚动条 3、html导出成excel工具方法增加单元格换行展示以及自适应换行高度功能 --- src/views/flowable/workflow/secondMaintenance/SecondMaintenanceApprovalModal.vue | 71 +++++++++++++++++++---------------- 1 files changed, 39 insertions(+), 32 deletions(-) diff --git a/src/views/flowable/workflow/secondMaintenance/SecondMaintenanceApprovalModal.vue b/src/views/flowable/workflow/secondMaintenance/SecondMaintenanceApprovalModal.vue index 73f1c4f..ba22c2a 100644 --- a/src/views/flowable/workflow/secondMaintenance/SecondMaintenanceApprovalModal.vue +++ b/src/views/flowable/workflow/secondMaintenance/SecondMaintenanceApprovalModal.vue @@ -154,14 +154,14 @@ </a-tab-pane> <template v-if="selectShenpiData.processDefinitionKey"> - <a-tab-pane key='3' tab='娴佺▼鍥�'> - <img :src="imageSrc" alt="Fetched Image"/> + <a-tab-pane key='3' tab='娴佺▼鍥�' style="overflow: auto"> + <img :src="imageSrc" v-if="imageSrc"/> </a-tab-pane> </template> <a-tab-pane key='4' tab='娴佽浆鑺傜偣'> <a-card> - <a-timeline style="padding:0 1% 0 12%" > + <a-timeline style="padding:0 1% 0 12%"> <a-timeline-item color='white' v-for="(item,index1) in hitaskDataSource" :key="index1"> <div class="bottom"> <p>澶勭悊浜猴細{{item.assignee_dictText}}</p> @@ -239,7 +239,7 @@ </a-row> </a-form-model> - <eamReportRepair-modal ref="modalForm" @ok="handleRepairComplete" @close="handleRepairClose"/> + <eamReportRepair-modal ref="modalForm" @ok="handleRepairComplete" @close="handleRepairClose"/> </a-spin> </j-modal> @@ -250,7 +250,7 @@ import { JVxeTableModelMixin } from '@/mixins/JVxeTableModelMixin.js' import { JVXETypes } from '@comp/jeecg/JVxeTable' import MaintenanceEquipmentSelect from '@views/eam/equipment/modules/MaintenanceEquipmentSelect' - import EamReportRepairModal from "@views/eam/repair/modules/EamReportRepairList/EamReportRepairModal.vue"; + import EamReportRepairModal from '@views/eam/repair/modules/EamReportRepairList/EamReportRepairModal.vue' export default { name: 'SecondMaintenanceApprovalModal', @@ -299,12 +299,12 @@ detail: '/eam/secondMaintenanceOrderDetail/queryList', approval: '/eam/secondMaintenanceOrder/approval', diagramView: '/assign/flow/diagramView', - queryHisTaskList:'/assign/flow/queryHisTaskList', + queryHisTaskList: '/assign/flow/queryHisTaskList' }, disableSubmit: false, selectedOperatorMaintenanceRowKeys: [], selectedRepairerMaintenanceRowKeys: [], - hitaskDataSource:[], + hitaskDataSource: [], detail: { operatorMaintenanceList: [], repairerMaintenanceList: [], @@ -383,7 +383,7 @@ }, // 鎿嶄綔鍒椾粎鍦ㄤ繚鍏讳腑鐘舵�佷笅鏄剧ず shouldShowActionColumn() { - return this.model.maintenanceStatus === 'UNDER_MAINTENANCE'; + return this.model.maintenanceStatus === 'UNDER_MAINTENANCE' } }, methods: { @@ -444,7 +444,7 @@ { handler: this.customValidator } ] } - ]; + ] // 浠呭湪淇濆吇涓姸鎬佷笅娣诲姞鎿嶄綔鍒� if (this.shouldShowActionColumn) { @@ -455,10 +455,10 @@ width: 150, slotName: 'action', fixed: 'right' - }); + }) } - return columns; + return columns }, /** @@ -469,7 +469,6 @@ this.spinning = true this.model = {} this.detail.operatorMaintenanceList = this.detail.repairerMaintenanceList = [] - this.handleTabToFirstTable() this.getBasicInformationByApi(record) this.getFlowChartImageByApi(record) this.getFlowTaskListByApi(record) @@ -503,6 +502,7 @@ that.model.taskId = record.id that.model.userId = record.assignee that.model.instanceId = record.procInstId + this.handleTabToFirstTable() } else { that.$notification.warning({ @@ -518,11 +518,11 @@ * @param record */ getFlowTaskListByApi(record) { - let parmhis={ + let parmhis = { 'procInstId': record.procInstId } - getAction(this.url.queryHisTaskList,parmhis).then(res=>{ - this.hitaskDataSource=res.result + getAction(this.url.queryHisTaskList, parmhis).then(res => { + this.hitaskDataSource = res.result }).finally( this.visible = true, console.log('this.approveData---->', this.approveData) @@ -720,15 +720,15 @@ this.model.maintenanceStatus !== 'UNDER_MAINTENANCE' || row.maintenanceResult === '1' || row.reportFlag === '1' - ); + ) }, handleRepairComplete(success) { if (success && this.currentRepairRow) { - this.$set(this.currentRepairRow, 'reportFlag', '1'); - this.$message.success("鎶ヤ慨宸叉垚鍔熸彁浜�"); + this.$set(this.currentRepairRow, 'reportFlag', '1') + this.$message.success('鎶ヤ慨宸叉垚鍔熸彁浜�') } - this.currentRepairRow = null; + this.currentRepairRow = null }, /** @@ -736,7 +736,7 @@ * @param exceptionDescription */ handleRepairReporting(row) { - this.currentRepairRow = row; // 瀛樺偍褰撳墠鎿嶄綔琛� + this.currentRepairRow = row // 瀛樺偍褰撳墠鎿嶄綔琛� let record = { faultDescription: row.exceptionDescription, equipmentId: this.model.equipmentId @@ -746,7 +746,7 @@ handleRepairClose(success) { if (!success && this.currentRepairRow) { - this.currentRepairRow = null; // 娓呴櫎鏈垚鍔熺殑鎿嶄綔 + this.currentRepairRow = null // 娓呴櫎鏈垚鍔熺殑鎿嶄綔 } }, @@ -789,6 +789,7 @@ } } } + /* 鍏ㄥ眬绂侀�夋牱寮� - 浣滅敤浜庢暣涓〉闈� */ html.submitting, html.submitting body { @@ -834,6 +835,7 @@ background-color: rgba(0, 0, 0, 0.1); /* 浣跨敤 RGBA 棰滆壊锛屽苟璁剧疆杈冧綆鐨勯�忔槑搴� */ margin: 20px 0; /* 鍒嗙晫绾夸笂涓嬬殑澶栬竟璺� */ } + .btn-custom { background-color: #4CAF50; /* 缁胯壊鑳屾櫙 */ color: white; /* 鐧借壊鏂囧瓧 */ @@ -852,13 +854,14 @@ font-weight: bold; font-size: 20px; /* 鎴栦綘闇�瑕佺殑浠讳綍澶у皬 */ } - .left_qiu{ + + .left_qiu { position: absolute; left: -74px; top: 0; - width:54px; + width: 54px; border-radius: 50%; - height:54px; + height: 54px; font-size: 13px; margin: auto; display: flex; @@ -868,20 +871,23 @@ background: #0099ff; transform: translate(0, 0); } - /deep/ .ant-timeline-item-tail{ + + /deep/ .ant-timeline-item-tail { left: -29px !important; } - .left_qiu span{ + + .left_qiu span { width: 3em; display: block; color: #fff; text-align: center; } - .img{ + + .img { width: 75%; } - .wrap{ + .wrap { clear: both; width: 100%; display: flex; @@ -889,13 +895,14 @@ border: 1px solid #ccc; /* background-color: aqua; */ } - .box{ - width:21%; - height:50px; + + .box { + width: 21%; + height: 50px; border-right: 1px solid #ccc; line-height: 50px; /* background: red; */ - text-align:center; + text-align: center; margin: auto; } -- Gitblit v1.9.3