From 3a8223b71d18205d40b894fd0b4c0fa1ca773e86 Mon Sep 17 00:00:00 2001 From: Lius <Lius2225@163.com> Date: 星期一, 13 十一月 2023 10:44:11 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/mdc-test' into mdc-test --- src/views/eam/DailyMaintenanceOrderList.vue | 162 ++++++++++++++++++++--------------------------------- 1 files changed, 61 insertions(+), 101 deletions(-) diff --git a/src/views/eam/DailyMaintenanceOrderList.vue b/src/views/eam/DailyMaintenanceOrderList.vue index 91351b9..3d0edaf 100644 --- a/src/views/eam/DailyMaintenanceOrderList.vue +++ b/src/views/eam/DailyMaintenanceOrderList.vue @@ -1,7 +1,7 @@ <template> <a-card :bordered="false" - title="鏃ュ父淇濆吇宸ュ崟" + title="浜岀骇淇濆吇" > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> @@ -66,6 +66,13 @@ icon="plus" v-has="'dailyMaintenanceOrder:add'" >鏂板</a-button> + <a-button + v-if="selectedRowKeys.length == 1 && selectionRows[0].status == '8'" + @click="handlePrintInfo(selectionRows[0])" + type="primary" + style="margin-left: 8px" + >绉讳氦鍗曟墦鍗� + </a-button> <!-- <a-button v-if="selectedRowKeys.length > 0" type="primary" @@ -117,7 +124,7 @@ <a-table ref="table" size="middle" - :scroll="{ x: 'calc(2500px + 50%)', y: 900 }" + :scroll="{ x: 'calc(2800px + 50%)', y: 900 }" bordered rowKey="id" :columns="columns" @@ -129,105 +136,17 @@ :rowSelection="rowSelection" :rowClassName="tableRowClass" > - <!-- :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}" --> - <!-- <span - slot="action" - slot-scope="text, record" - > - <a-popconfirm - title="纭畾涓嬪彂宸ュ崟鍚�?" - @confirm="() => handleOrderIssue(record)" - > - <a v-if="record.status === '1'">涓嬪彂</a> - </a-popconfirm> - <a-divider - v-if="record.status === '1'" - type="vertical" - /> - <a-popconfirm - title="纭畾鎾ゅ洖宸ュ崟鍚�?" - @confirm="() => handleOrderReset(record)" - > - <a v-if="record.status === '2'">鎾ゅ洖</a> - </a-popconfirm> - <a-divider - v-if="record.status === '2'" - type="vertical" - /> - <a-popconfirm - title="纭畾鎭㈠宸ュ崟鍚�?" - @confirm="() => handleOrderRecover(record)" - > - <a v-if="record.status === '7'">鎭㈠</a> - </a-popconfirm> - <a-divider - v-if="record.status === '7'" - type="vertical" - /> - <a-popconfirm - title="纭畾浣滃簾宸ュ崟鍚�?" - @confirm="() => handleOrderCancel(record)" - > - <a v-if="record.status === '2'">浣滃簾</a> - </a-popconfirm> - <a-divider - v-if="record.status === '2'" - type="vertical" - /> - <a-popconfirm - title="纭畾棰嗗彇宸ュ崟鍚�?" - @confirm="() => handleOrderGet(record)" - > - <a v-if="record.status === '2'">棰嗗彇</a> - </a-popconfirm> - <a-divider - v-if="record.status === '2'" - type="vertical" - /> - <a - v-if="record.status === '3' || record.status === '4' ||record.status === '5' ||record.status === '7' " - @click="handleOrderExe(record)" - >鎵ц</a> - <a-divider - v-if="record.status === '3' || record.status === '4' ||record.status === '5' ||record.status === '7' " - type="vertical" - /> - <a - v-if="record.status === '1'" - @click="handleEdit(record)" - >缂栬緫</a> - <a-divider - v-if="record.status === '1'" - type="vertical" - /> - <a-dropdown> - <a class="ant-dropdown-link">鏇村 <a-icon type="down" /></a> - <a-menu slot="overlay"> - <a-menu-item> - <a @click="handleDetail(record)">璇︽儏</a> - </a-menu-item> - <a-menu-item> - <a-popconfirm - title="纭畾鍒犻櫎鍚�?" - @confirm="() => handleDelete(record.id)" - > - <a v-if="record.status === '1'">鍒犻櫎</a> - </a-popconfirm> - </a-menu-item> - </a-menu> - </a-dropdown> - </span> --> <span slot="action" slot-scope="text, record" > <a-popconfirm - title="纭畾涓嬪彂宸ュ崟鍚�?" + title="纭畾鎺ユ敹宸ュ崟鍚�?" @confirm="() => handleOrderIssue(record)" v-has="'dailyMaintenanceOrder:issue'" > - <a v-if="record.status == '1'">涓嬪彂</a> + <a v-if="record.status == '1'">鎺ユ敹</a> </a-popconfirm> <a-divider v-if="record.status == '1'" @@ -313,6 +232,14 @@ v-if="record.status === '1'" type="vertical" /> + <a + v-if="record.status === '5' || record.status === '8'" + @click="handleFinish(record)" + >瀹屽伐绉讳氦鍗�</a> + <a-divider + v-if="record.status === '5' || record.status === '8'" + type="vertical" + /> <a-dropdown> <a class="ant-dropdown-link">鏇村 <a-icon type="down" /></a> <a-menu slot="overlay"> @@ -351,6 +278,10 @@ ref="modalForm" @ok="modalFormOk" ></maintenance-order-modal> + <finish-devolution-modal + ref="FinishDevolutionModal" + @ok="modalFormOk" + ></finish-devolution-modal> <maintenance-order-assign-modal ref="MaintenanceOrderAssignModal" @ok="modalFormOk" @@ -368,6 +299,7 @@ import { mixinDevice } from '@/utils/mixin' import { JeecgListMixin } from '@/mixins/JeecgListMixin' import MaintenanceOrderModal from './modules/dailyMaintenanceOrder/MaintenanceOrderModal' +import FinishDevolutionModal from './modules/dailyMaintenanceOrder/FinishDevolutionModal' import MaintenanceOrderAssignModal from './modules/dailyMaintenanceOrder/MaintenanceOrderAssignModal' import DailyMaintenanceOrderExeDrawer from './modules/dailyMaintenanceOrder/DailyMaintenanceOrderExeDrawer' import { getAction, postAction, requestPut } from '@/api/manage' @@ -377,12 +309,14 @@ mixins: [JeecgListMixin, mixinDevice], components: { MaintenanceOrderModal, + FinishDevolutionModal, MaintenanceOrderAssignModal, DailyMaintenanceOrderExeDrawer }, data() { return { - description: '鏃ュ父淇濆吇宸ュ崟', + description: '浜岀骇淇濆吇宸ュ崟', + queryParam: { maintenanceType: '2' }, // 琛ㄥご columns: [ { @@ -396,16 +330,21 @@ } }, { - title: '鐘舵��', - align: "center", - dataIndex: 'statusName' - }, - { title: '淇濆吇宸ュ崟鍙�', align: "center", dataIndex: 'num', scopedSlots: { customRender: 'num' } }, + { + title: '鐘舵��', + align: "center", + dataIndex: 'statusName' + }, + // { + // title: '淇濆吇绫诲瀷', + // align: "center", + // dataIndex: 'maintenanceTypeName', + // }, { title: '淇濆吇鍛ㄦ湡', align: "center", @@ -417,7 +356,7 @@ dataIndex: 'assignModeName' }, { - title: '璁惧缂栫爜', + title: '缁熶竴缂栫爜', align: "center", dataIndex: 'equipmentNum', }, @@ -487,6 +426,11 @@ dataIndex: 'maintenanceUserName' }, { + title: '闂鍙婄浉搴斿鐞嗘帾鏂芥弿杩�', + align: "center", + dataIndex: 'description' + }, + { title: '鍒涘缓浜�', align: "center", dataIndex: 'createBy' @@ -552,9 +496,14 @@ this.selectionRows = selectionRows; }, + handlePrintInfo(record) { + let href = `${window._CONFIG['domianURL']}/jmreport/view/857408393168490496?id=` + record.id; //缃戠珯閾炬帴 + window.open(href, "_blank"); + }, + handleOrderExe(record) { this.$refs.DailyMaintenanceOrderExeDrawer.visible = true - this.$refs.DailyMaintenanceOrderExeDrawer.title = '鏃ュ父淇濆吇宸ュ崟鎵ц' + this.$refs.DailyMaintenanceOrderExeDrawer.title = '浜岀骇淇濆吇宸ュ崟鎵ц' this.$refs.DailyMaintenanceOrderExeDrawer.handleShow(record) if (record.status === '3') { this.$refs.DailyMaintenanceOrderExeDrawer.buttonDistable = true//淇濆瓨銆佹殏瀛樸�佹姤宸� @@ -573,6 +522,12 @@ this.$refs.DailyMaintenanceOrderExeDrawer.revocationDistable = true this.$refs.DailyMaintenanceOrderExeDrawer.SWbuttonDistable = true } + }, + + handleFinish: function (record) { + this.$refs.FinishDevolutionModal.edit(record); + this.$refs.FinishDevolutionModal.title = "鐢熶骇璁惧浜岀骇淇濆吇瀹屽伐绉讳氦鍗�"; + this.$refs.FinishDevolutionModal.disableSubmit = false; }, handleOrderIssue(record) { @@ -641,6 +596,11 @@ this.$refs.MaintenanceOrderAssignModal.title = '宸ュ崟鏀规淳' this.$refs.MaintenanceOrderAssignModal.disableSubmit = false }, + + searchReset() { + this.queryParam = { maintenanceType: '2' } + this.loadData(1); + }, // modalFormOk() { // alert(0) // // 鏂板/淇敼 鎴愬姛鏃讹紝閲嶈浇鍒楄〃 @@ -678,7 +638,7 @@ font-weight: bold; } .yellow { - color: yellow; + color: rgba(255, 255, 0, 0.443); font-weight: bold; } .fontweight { -- Gitblit v1.9.3