From 6dba5119e2fd1a395d4242d5bfc56d57a3366ee3 Mon Sep 17 00:00:00 2001 From: zhaowei <zhaowei> Date: 星期二, 04 三月 2025 15:55:01 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- src/views/eam/modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer.vue | 2 src/views/eam/DailyInspectionOrderList.vue | 4 src/views/eam/EquipmentListOfAll.vue | 424 ++++++++++++++++-------- src/views/eam/modules/equipmentNew/DailyInspectionOrderListComponent.vue | 572 +++++++++++++++++++++++++++++++++ 4 files changed, 860 insertions(+), 142 deletions(-) diff --git a/src/views/eam/DailyInspectionOrderList.vue b/src/views/eam/DailyInspectionOrderList.vue index 82c5bae..4a5247f 100644 --- a/src/views/eam/DailyInspectionOrderList.vue +++ b/src/views/eam/DailyInspectionOrderList.vue @@ -1,7 +1,7 @@ <template> <a-card :bordered="false" - title="鑷富缁存姢鐐规宸ュ崟" + title="" > <!-- 鏌ヨ鍖哄煙 --> <div class="table-page-search-wrapper"> @@ -103,7 +103,7 @@ style="margin-left: 8px" >鏌ヨ</a-button> <a-button - type="primary" + type="info" @click="searchReset" icon="reload" style="margin-left: 8px" diff --git a/src/views/eam/EquipmentListOfAll.vue b/src/views/eam/EquipmentListOfAll.vue index c69168c..9239a35 100644 --- a/src/views/eam/EquipmentListOfAll.vue +++ b/src/views/eam/EquipmentListOfAll.vue @@ -18,7 +18,7 @@ :md='8' :sm='24'> <a-form-item - label="缁熶竴缂栧彿缇�" + label="缁熶竴缂栫爜缇�" :labelCol="labelCol" :wrapperCol="wrapperCol" > @@ -372,6 +372,13 @@ v-has="'equipmentAccount:add&delete&import&Edit'" >璐ㄤ繚鏈熷彉鏇�</a-button> <a-button + :disabled="selectedRowKeys.length==0" + @click="batchDel" + type="danger" + icon="delete" + v-has="'equipmentAccount:add&delete&import&Edit'" + >鎵归噺鍒犻櫎</a-button> + <a-button @click="handleUpdateKeyEquipment" type="primary" icon="calendar" @@ -558,6 +565,51 @@ :length="8" /> </span> + <span + slot="yseNoInspectionStandard" + slot-scope="text" + > + <a-icon + type="check" + style="color: chartreuse;" + v-if="text==='0'" + /> + <a-icon + type="close" + v-else + style="color:red;" + /> + </span> + <span + slot="yseNoMaintenance2Standard" + slot-scope="text" + > + <a-icon + type="check" + style="color: chartreuse;" + v-if="text==='0'" + /> + <a-icon + type="close" + v-else + style="color:red;" + /> + </span> + <span + slot="yseNoMaintenance3Standard" + slot-scope="text" + > + <a-icon + type="check" + style="color: chartreuse;" + v-if="text==='0'" + /> + <a-icon + type="close" + v-else + style="color:red;" + /> + </span> <template slot="num" @@ -632,8 +684,16 @@ <a-tabs defaultActiveKey="1"> <a-tab-pane - tab="宸ヨ壓鍙傛暟" + tab="璁惧鏂囨。" key="1" + forceRender + > + <EquipmentDocumentList :mainId="selectedMainId" /> + </a-tab-pane> + <a-tab-pane + tab="宸ヨ壓鍙傛暟" + key="2" + v-if="isOpenProcess" > <EquipmentProcessParametersList :mainId="selectedMainId" @@ -642,20 +702,13 @@ </a-tab-pane> <a-tab-pane tab="璁惧绮惧害" - key="2" - forceRender + key="3" + v-if="isOpenPrecision" > <EquipmentPrecisionParametersList :isOpen="isOpenPrecision" :mainId="precisionParametersTemplateId" /> - </a-tab-pane> - <a-tab-pane - tab="璁惧鏂囨。" - key="3" - forceRender - > - <EquipmentDocumentList :mainId="selectedMainId" /> </a-tab-pane> <a-tab-pane tab="澶囦欢" @@ -679,12 +732,13 @@ <equipment-update-warranty-list :mainId="selectedMainId" /> </a-tab-pane> <a-tab-pane - tab="鏃ヤ繚鏍囧噯" + tab="鐐规鏍囧噯" key="7" forceRender > <daily-maintenance-list :mainId="selectedMainId"></daily-maintenance-list> </a-tab-pane> + <a-tab-pane tab="浜屼繚鏍囧噯" key="8" @@ -698,6 +752,13 @@ forceRender > <third-maintenance-list :mainId="selectedMainId"></third-maintenance-list> + </a-tab-pane> + <a-tab-pane + tab="鐐规宸ュ崟" + key="10" + forceRender + > + <daily-inspection-order-list-component :mainId="selectedMainId"></daily-inspection-order-list-component> </a-tab-pane> </a-tabs> <equipment-modal @@ -734,7 +795,7 @@ import { mixinDevice } from '@/utils/mixin' import JEllipsis from '@/components/jeecg/JEllipsis' import EquipmentModal from './modules/equipmentNew/EquipmentModal' -import { getAction, downFile } from '@/api/manage' +import { getAction, downFile, deleteAction } from '@/api/manage' import EquipmentProcessParametersList from './modules/equipmentNew/EquipmentProcessParametersList' import EquipmentDocumentList from './modules/equipmentNew/EquipmentDocumentList' import EquipmentPrecisionParametersList from './modules/equipmentNew/EquipmentPrecisionParametersList' @@ -755,6 +816,7 @@ import SecondMaintenanceList from './modules/equipmentNew/SecondMaintenanceList.vue' import ThirdMaintenanceList from './modules/equipmentNew/ThirdMaintenanceList.vue' import KeyEquipmentUpdateModel from './modules/equipmentNew/edit/KeyEquipmentUpdateModel.vue' +import DailyInspectionOrderListComponent from './modules/equipmentNew/DailyInspectionOrderListComponent.vue' export default { name: "EquipmentList", @@ -781,6 +843,7 @@ ThirdMaintenanceList, KeyEquipmentUpdateModel, JEllipsis, + DailyInspectionOrderListComponent, }, data() { return { @@ -797,16 +860,61 @@ return parseInt(index) + 1 }, width: 50, + fixed: 'left', }, { - title: '璁惧绫诲瀷', + title: '缁熶竴缂栫爜', + align: "center", + dataIndex: 'num', + scopedSlots: { customRender: 'num' }, + fixed: 'left', + }, + { + title: '璁惧鍚嶇О', + align: "center", + dataIndex: 'name', + scopedSlots: { customRender: 'name' }, + fixed: 'left', + }, + { + title: '浣跨敤閮ㄩ棬', + align: "center", + dataIndex: 'useId_dictText', + }, + { + title: '涓績', + align: "center", + dataIndex: 'workCenterId_dictText', + }, + { + title: '宸ュ尯', + align: "center", + dataIndex: 'factoryModelId_dictText', + }, + { + title: '宸ユ', + align: "center", + dataIndex: 'areaId_dictText', + }, + { + title: '缁存姢閮ㄩ棬', + align: "center", + dataIndex: 'manageId_dictText', + }, + { + title: '缁翠慨鐝粍', + align: "center", + dataIndex: 'teamId_dictText', + }, + { + title: '璁惧鎵�灞炲垎绫�', align: "center", dataIndex: 'equipmentCategoryId_dictText', }, { - title: '鏄惁鐢熶骇绾胯澶�', + title: 'ABC鏍囪瘑', align: "center", - dataIndex: 'isLineEquip_dictText', + dataIndex: 'equipmentImportanceId', }, { title: '鍏抽敭璁惧鏍囪瘑', @@ -814,16 +922,110 @@ dataIndex: 'specificEquipment_dictText', }, { - title: '缁熶竴缂栫爜', + title: '瀹夊叏閰嶇疆', align: "center", - dataIndex: 'num', - scopedSlots: { customRender: 'num' }, + dataIndex: 'securityConfiguration', }, { - title: '璁惧鍚嶇О', + title: '鍐峰嵈绯荤粺', align: "center", - dataIndex: 'name', - scopedSlots: { customRender: 'name' }, + dataIndex: 'coolingSystem', + }, + { + title: '鐏伀鍣�', + align: "center", + dataIndex: 'fireExtinguisher', + }, + { + title: '鐏伀鍣ㄦ湁鏁堟湡', + align: "center", + dataIndex: 'fireExtinguisherValidityPeriod', + }, + { + title: '鎿嶄綔绯荤粺', + align: "center", + dataIndex: 'operatingSystem', + }, + { + title: '绯荤粺', + align: "center", + dataIndex: 'system', + }, + { + title: '璁惧绔彛', + align: "center", + dataIndex: 'port', + }, + { + title: '鍧愭爣鏁伴噺', + align: "center", + dataIndex: 'coordinateNum', + }, + { + title: '璁惧鐘舵��', + align: "center", + dataIndex: 'equipmentStatus_dictText', + }, + { + title: '鎶�鏈姸鎬�', + align: "center", + dataIndex: 'technologyStatus_dictText', + scopedSlots: { customRender: 'technologyStatus' }, + }, + { + title: '閲嶉噺', + align: "center", + dataIndex: 'equipmentUda3', + }, + { + title: '閲嶉噺璁¢噺鍗曚綅', + align: "center", + dataIndex: 'equipmentUda4_dictText', + }, + { + title: '鍔熻兘浣嶇疆', + align: "center", + dataIndex: 'equipmentUda5', + }, + { + title: '瀹夎浣嶇疆', + align: "center", + dataIndex: 'equipmentUda2', + }, + { + title: '鍑哄巶鏃ユ湡', + align: "center", + dataIndex: 'leaveFactoryDate', + }, + { + title: '绔嬮」鍗″彿', + align: "center", + dataIndex: 'projectApprovalNo', + }, + { + title: '璧勯噾鏉ユ簮', + align: "center", + dataIndex: 'fundSource', + }, + { + title: '楠屾敹鏃ユ湡', + align: "center", + dataIndex: 'acceptanceCheckDate', + }, + { + title: '鍑哄巶缂栧彿', + align: "center", + dataIndex: 'factoryNo', + }, + { + title: '璧勪骇鍒堕�犲晢', + align: "center", + dataIndex: 'constructorId_dictText', + }, + { + title: '璧勪骇鐨勬潵婧愬浗瀹�', + align: "center", + dataIndex: 'sourceCountry', }, { title: '鍨嬪彿', @@ -831,7 +1033,7 @@ dataIndex: 'model', }, { - title: '瑙勬牸', + title: '璁惧瑙勬牸', align: "center", dataIndex: 'specification', }, @@ -841,31 +1043,49 @@ dataIndex: 'gpo', }, { - title: '浣跨敤閮ㄩ棬', + title: '鍒涘缓浜�', align: "center", - dataIndex: 'useId_dictText', + dataIndex: 'createBy' }, - // { - // title: '缁存姢閮ㄩ棬', - // align: "center", - // dataIndex: 'manageId_dictText', - // }, - // { - // title: '缁翠慨鐝粍', - // align: "center", - // dataIndex: 'teamId_dictText', - // }, { - title: 'ABC鏍囪瘑', + title: '鍒涘缓鏃堕棿', align: "center", - dataIndex: 'equipmentImportanceId', + dataIndex: 'createTime', }, - { - title: '鎶�鏈姸鎬�', + title: '鏇存柊浜�', align: "center", - dataIndex: 'technologyStatus_dictText', - scopedSlots: { customRender: 'technologyStatus' }, + dataIndex: 'updateBy' + }, + { + title: '鏇存柊鏃堕棿', + align: "center", + dataIndex: 'updateTime', + }, + { + title: '璐ㄤ繚寮�濮嬫棩鏈�', + align: "center", + dataIndex: 'warrantyStart' + }, + { + title: '璐ㄤ繚缁撴潫鏃ユ湡', + align: "center", + dataIndex: 'warrantyEnd', + }, + { + title: '璧勪骇鐘舵��', + align: "center", + dataIndex: 'propertyStatus_dictText', + }, + { + title: '涓変繚鏃ユ湡', + align: "center", + dataIndex: 'thirdMaintenanceTime', + }, + { + title: '鎶�鏈壌瀹氭棩鏈�', + align: "center", + dataIndex: 'technologyStatusQualificationTime', }, { title: '鎶�鏈姸鎬侀壌瀹氱被鍨�', @@ -878,6 +1098,11 @@ dataIndex: 'nextTechnologyStatusQualificationTime', }, { + title: '鏄惁鐢熶骇绾胯澶�', + align: "center", + dataIndex: 'isLineEquip_dictText', + }, + { title: '鐢熶骇绾跨紪鍙�', align: "center", dataIndex: 'lineId_dictText', @@ -887,103 +1112,6 @@ align: "center", dataIndex: 'isMeta_dictText', }, - // { - // title: '瀹夊叏閰嶇疆', - // align: "center", - // dataIndex: 'securityConfiguration', - // }, - // { - // title: '鍐峰嵈绯荤粺', - // align: "center", - // dataIndex: 'coolingSystem', - // }, - // { - // title: '鐏伀鍣�', - // align: "center", - // dataIndex: 'fireExtinguisher', - // }, - - - // { - // title: '鎿嶄綔绯荤粺', - // align: "center", - // dataIndex: 'operatingSystem', - // }, - // { - // title: '绯荤粺', - // align: "center", - // dataIndex: 'system', - // }, - // { - // title: '璁惧绔彛', - // align: "center", - // dataIndex: 'port', - // }, - // { - // title: '鍧愭爣鏁伴噺', - // align: "center", - // dataIndex: 'coordinateNum', - // }, - // { - // title: '璁惧鐘舵��', - // align: "center", - // dataIndex: 'equipmentStatus_dictText', - // }, - // { - // title: '閲嶉噺', - // align: "center", - // dataIndex: 'equipmentUda3', - // }, - // { - // title: '閲嶉噺璁¢噺鍗曚綅', - // align: "center", - // dataIndex: 'equipmentUda4_dictText', - // }, - // { - // title: '鍔熻兘浣嶇疆', - // align: "center", - // dataIndex: 'equipmentUda5', - // }, - // { - // title: '瀹夎浣嶇疆', - // align: "center", - // dataIndex: 'equipmentUda2', - // }, - // { - // title: '鍑哄巶鏃ユ湡', - // align: "center", - // dataIndex: 'leaveFactoryDate', - // }, - // { - // title: '绔嬮」鍗″彿', - // align: "center", - // dataIndex: 'projectApprovalNo', - // }, - // { - // title: '璧勯噾鏉ユ簮', - // align: "center", - // dataIndex: 'fundSource', - // }, - // { - // title: '楠屾敹鏃ユ湡', - // align: "center", - // dataIndex: 'acceptanceCheckDate', - // }, - // { - // title: '鍑哄巶缂栧彿', - // align: "center", - // dataIndex: 'factoryNo', - // }, - // { - // title: '璧勪骇鍒堕�犲晢', - // align: "center", - // dataIndex: 'constructorId_dictText', - // }, - // { - // title: '璧勪骇鐨勬潵婧愬浗瀹�', - // align: "center", - // dataIndex: 'sourceCountry', - // }, { title: '宸ヨ壓鍙傛暟绠$悊', align: "center", @@ -1005,6 +1133,24 @@ title: '绮惧害鍙傛暟妯℃澘', align: "center", dataIndex: 'precisionParametersTemplateId_dictText', + }, + { + title: '鏈夋棤鐐规鏍囧噯', + align: "center", + dataIndex: 'yseNoInspectionStandard', + scopedSlots: { customRender: 'yseNoInspectionStandard' } + }, + { + title: '鏈夋棤浜屼繚鏍囧噯', + align: "center", + dataIndex: 'yseNoMaintenance2Standard', + scopedSlots: { customRender: 'yseNoMaintenance2Standard' } + }, + { + title: '鏈夋棤涓変繚鏍囧噯', + align: "center", + dataIndex: 'yseNoMaintenance3Standard', + scopedSlots: { customRender: 'yseNoMaintenance3Standard' } }, // { // title: '澶囨敞', @@ -1099,7 +1245,7 @@ this.selectedMainId = '' }, onSelectChange(selectedRowKeys, selectionRows) { - if (selectedRowKeys.length == 1) { + if (selectedRowKeys.length >= 1) { this.selectedMainId = selectedRowKeys[0] this.precisionParametersTemplateId = selectionRows[0].precisionParametersTemplateId; this.isOpenProcess = selectionRows[0].processParameters == 1; diff --git a/src/views/eam/modules/equipmentNew/DailyInspectionOrderListComponent.vue b/src/views/eam/modules/equipmentNew/DailyInspectionOrderListComponent.vue new file mode 100644 index 0000000..85d77f1 --- /dev/null +++ b/src/views/eam/modules/equipmentNew/DailyInspectionOrderListComponent.vue @@ -0,0 +1,572 @@ +<template> + <a-card + :bordered="false" + title="" + > + <!-- table鍖哄煙-begin --> + <div> + <div + class="ant-alert ant-alert-info" + style="margin-bottom: 16px;" + > + <i class="anticon anticon-info-circle ant-alert-icon"></i> 宸查�夋嫨 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>椤� + <a + style="margin-left: 24px" + @click="onClearSelected" + >娓呯┖</a> + </div> + + <a-table + ref="table" + size="middle" + :scroll="{ x: 'calc(2200px + 50%)', y: 900 }" + bordered + rowKey="id" + :columns="columns" + :dataSource="dataSource" + :pagination="ipagination" + :loading="loading" + class="j-table-force-nowrap" + @change="handleTableChange" + :rowClassName="tableRowClass" + > + <!-- :rowSelection="rowSelection" --> + <!-- :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}" --> + + <span + slot="action" + slot-scope="text, record" + > + <a-popconfirm + title="纭畾鎺ユ敹宸ュ崟鍚�?" + @confirm="() => handleOrderIssue(record)" + v-has="'dailyInspectionOrder:issue'" + > + <a v-if="record.status == '1'">鎺ユ敹</a> + </a-popconfirm> + <a-divider + v-if="record.status == '1'" + type="vertical" + /> + <a-popconfirm + title="纭畾鎾ゅ洖宸ュ崟鍚�?" + @confirm="() => handleOrderReset(record)" + v-has="'dailyInspectionOrder:issue'" + > + <a v-if="record.status == '2'">鎾ゅ洖</a> + </a-popconfirm> + <a-divider + v-if="record.status == '2'" + type="vertical" + /> + <!-- <a-popconfirm + title="纭畾鎭㈠宸ュ崟鍚�?" + @confirm="() => handleOrderRecover(record)" + v-has="'dailyInspectionOrder:recover'" + > + <a v-if="record.status == '7'">鎭㈠</a> + </a-popconfirm> + <a-divider + v-if="record.status == '7'" + type="vertical" + /> --> + <!-- <a-popconfirm + title="纭畾浣滃簾宸ュ崟鍚�?" + @confirm="() => handleOrderCancel(record)" + v-has="'dailyInspectionOrder:recover'" + > + <a v-if="record.status == '2'">浣滃簾</a> + </a-popconfirm> + <a-divider + v-if="record.status == '2'" + type="vertical" + /> --> + <a-popconfirm + title="纭畾棰嗗彇宸ュ崟鍚�?" + @confirm="() => handleOrderGet(record)" + v-has="'dailyInspectionOrder:get'" + > + <a v-if="record.status == '2' && record.assignMode == '1'">棰嗗彇</a> + </a-popconfirm> + <!-- <a + v-if="record.status == '2' && record.assignMode == '2' " + @click="handleAssignOrder(record)" + v-has="'dailyInspectionOrder:assign'" + >娲惧伐</a> --> + <!-- <a + v-if="record.status == '2'&& record.assignMode == '3' && record.inspectionUserName != null " + @click="handleAssignOrder(record)" + v-has="'dailyInspectionOrder:assign'" + >鏀规淳</a> + <a + v-if="record.status == '3'" + @click="handleAssignOrder(record)" + v-has="'dailyInspectionOrder:assign'" + >鏀规淳</a>--> + <a-divider + v-if="record.status == '2'" + type="vertical" + /> + <a-divider + v-if="record.status === '3'" + type="vertical" + /> + <a + v-if="record.status === '3' || record.status === '4' " + @click="handleOrderExe(record)" + v-has="'dailyInspectionOrder:exe'" + >鎵ц</a> + <a-divider + v-if="record.status === '3' || record.status === '4' " + type="vertical" + /> + <a-popconfirm + title="缁翠慨浜虹‘璁ゅ畬宸ュ悧?" + @confirm="() => handleOrderRepairConfirm(record)" + v-has="'dailyInspectionOrder:repairConfirm'" + > + <a v-if="record.status == '5'">缁翠慨纭</a> + </a-popconfirm> + <a-divider + v-if="record.status == '5'" + type="vertical" + /> + <a + v-if="record.status === '1'" + @click="handleEdit(record)" + v-has="'dailyInspectionOrder:edit'" + >缂栬緫</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)" + v-has="'dailyInspectionOrder:delete'" + > + <a v-if="record.status === '1'">鍒犻櫎</a> + </a-popconfirm> + </a-menu-item> + </a-menu> + </a-dropdown> + </span> + + <span + slot="num" + slot-scope="text, record" + > + <a + v-if="record.status === '3' || record.status === '4' ||record.status === '5' ||record.status === '6' " + class="lot" + @click="handleOrderExe(record)" + >{{record.num}}</a> + <span v-else>{{record.num}}</span> + </span> + + </a-table> + </div> + + <daily-inspection-order-modal + ref="modalForm" + @ok="modalFormOk" + ></daily-inspection-order-modal> + + <inspection-order-assign-modal + ref="InspectionOrderAssignModal" + @ok="modalFormOk" + ></inspection-order-assign-modal> + + <inspection-order-exe-modal + ref="InspectionOrderExeModal" + @ok="modalFormOk" + ></inspection-order-exe-modal> + <daily-inspection-order-exe-drawer + ref="DailyInspectionOrderExeDrawer" + @ok="modalFormOk" + ></daily-inspection-order-exe-drawer> + + </a-card> +</template> + +<script> + +import '@/assets/less/TableExpand.less' +import { mixinDevice } from '@/utils/mixin' +import { JeecgListMixin } from '@/mixins/JeecgListMixin' +import DailyInspectionOrderModal from '@/views/eam/modules/dailyInspectionOrder/DailyInspectionOrderModal' +import InspectionOrderAssignModal from '@/views/eam/modules/dailyInspectionOrder/InspectionOrderAssignModal' +import InspectionOrderExeModal from '@/views/eam/modules/dailyInspectionOrder/InspectionOrderExeModal' +import DailyInspectionOrderExeDrawer from '@/views/eam/modules/dailyInspectionOrder/DailyInspectionOrderExeDrawer' +import { getAction, postAction, requestPut } from '@/api/manage' +import moment from 'moment' + +export default { + name: 'DailyInspectionOrderListComponent', + mixins: [JeecgListMixin, mixinDevice], + components: { + DailyInspectionOrderModal, + InspectionOrderExeModal, + DailyInspectionOrderExeDrawer, + InspectionOrderAssignModal + }, + props:{ + mainId:{ + type:String, + default:'', + required:false + } + }, + watch:{ + mainId:{ + immediate: true, + handler(val) { + if(!this.mainId){ + this.queryParam['equipmentId'] = 'NAN' + this.loadData(1); + }else{ + this.queryParam['equipmentId'] = val + this.loadData(1); + } + } + } + }, + data() { + return { + description: '鑷富缁存姢鐐规宸ュ崟', + finishTime: [], + // 琛ㄥご + columns: [ + { + title: '#', + dataIndex: '', + key: 'rowIndex', + width: 60, + align: "center", + customRender: function (t, r, index) { + return parseInt(index) + 1; + } + }, + + { + title: '鐐规宸ュ崟鍙�', + align: "center", + dataIndex: 'num', + scopedSlots: { customRender: 'num' } + }, + { + title: '缁熶竴缂栫爜', + align: "center", + dataIndex: 'equipmentNum' + }, + { + title: '鐘舵��', + align: "center", + width: 100, + dataIndex: 'statusName' + }, + { + title: '鐐规鍛ㄦ湡', + align: "center", + width: 100, + dataIndex: 'inspectionCycleName' + }, + // { + // title: '鐐规鏃ユ湡', + // align: "center", + // dataIndex: 'inspectionDate', + // customRender: function (text) { + // return !text ? "" : (text.length > 10 ? text.substr(0, 10) : text) + // } + // }, + // { + // title: '鐐规鏃堕棿', + // align: "center", + // dataIndex: 'inspectionTime', + // // customRender: function (text) { + // // return !text ? "" : (text.length > 10 ? text.substr(11, 20) : text) + // // } + // }, + // { + // title: '鎴鏃堕棿', + // align: "center", + // dataIndex: 'inspectionDeadline', + // }, + + { + title: '璁惧鍚嶇О', + align: "center", + dataIndex: 'equipmentName' + }, + { + title: '璁惧鍨嬪彿', + align: "center", + dataIndex: 'equipmentModel' + }, + { + title: '浣跨敤閮ㄩ棬', + align: "center", + dataIndex: 'useDepartName' + }, + { + title: '璐d换鐝粍', + align: "center", + dataIndex: 'teamName' + }, + // { + // title: '寮�宸ユ潯浠�', + // align: "center", + // dataIndex: 'startWorkCondition', + // customRender: (text) => { + // if (text == '1') { + // return "鏄�"; + // } else if (text == '0') { + // return "鍚�"; + // } + // }, + // }, + // { + // title: '鐐规鏍囧噯缂栫爜', + // align: "center", + // dataIndex: 'inspectionStandardNum' + // }, + + // { + // title: '娲惧伐鏂瑰紡', + // align: "center", + // dataIndex: 'assignModeName' + // }, + // { + // title: '鐐规缁撴灉', + // align: "center", + // dataIndex: 'result' + // }, + { + title: '鐐规浜�', + align: "center", + dataIndex: 'inspectionUserName' + }, + { + title: '鐐规鏃堕棿', + align: "center", + dataIndex: 'actualEndTime', + // customRender: function (text) { + // return !text ? "" : (text.length > 10 ? text.substr(0, 10) : text) + // } + }, + { + title: '缁翠慨纭浜�', + align: "center", + dataIndex: 'repairConfirmPerson' + }, + { + title: '纭鏃堕棿', + align: "center", + dataIndex: 'repairConfirmDate', + // customRender: function (text) { + // return !text ? "" : (text.length > 10 ? text.substr(0, 10) : text) + // } + }, + // { + // title: '鍒涘缓浜�', + // align: "center", + // dataIndex: 'createBy' + // }, + // { + // title: '鍒涘缓鏃ユ湡', + // align: "center", + // dataIndex: 'createTime', + // }, + + { + title: '鎿嶄綔', + dataIndex: 'action', + align: "center", + fixed: "right", + width: 230, + scopedSlots: { customRender: 'action' } + } + ], + url: { + list: "/eam/inspectionOrder/getInspectionOrderList", + delete: "/eam/inspectionOrder/delete", + deleteBatch: "/eam/inspectionOrder/deleteBatch", + exportXlsUrl: "/eam/inspectionOrder/exportXls", + importExcelUrl: "eam/inspectionOrder/importExcel", + edit: "/eam/inspectionOrder/editStatus", + orderGet: "/eam/inspectionOrder/orderGet", + }, + + } + }, + created() { + }, + computed: { + importExcelUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`; + }, + rowSelection() { + return { + type: 'checkbox', + onChange: (selectedRowKeys, selectedRows) => { + this.selectedRowKeys = selectedRowKeys; + this.onSelectChange(selectedRows); + }, + getCheckboxProps: record => ({ + props: { + disabled: record.distable + }, + }), + selectedRowKeys: this.selectedRowKeys, + }; + }, + }, + methods: { + + // handleOrderExe(record) { + // this.$refs.InspectionOrderExeModal.visible = true + // this.$refs.InspectionOrderExeModal.title = '鏃ュ父鐐规鎵ц' + // this.$refs.InspectionOrderExeModal.handleShow(record) + // }, + //鏀规淳 + handleAssignOrder: function (record) { + this.$refs.InspectionOrderAssignModal.edit(record) + this.$refs.InspectionOrderAssignModal.title = '宸ュ崟鏀规淳' + this.$refs.InspectionOrderAssignModal.disableSubmit = false + }, + handleOrderExe(record) { + this.$refs.DailyInspectionOrderExeDrawer.visible = true + this.$refs.DailyInspectionOrderExeDrawer.title = '鑷富缁存姢鐐规鎵ц' + this.$refs.DailyInspectionOrderExeDrawer.handleShow(record) + if (record.status === '3') { + this.$refs.DailyInspectionOrderExeDrawer.buttonDistable = true//淇濆瓨銆佹殏瀛樸�佹姤宸� + this.$refs.DailyInspectionOrderExeDrawer.revocationDistable = true//鎾ら攢鎸夐挳 + this.$refs.DailyInspectionOrderExeDrawer.SWbuttonDistable = false//寮�宸ユ寜閽� + } else if (record.status === '4') { + this.$refs.DailyInspectionOrderExeDrawer.buttonDistable = false + this.$refs.DailyInspectionOrderExeDrawer.revocationDistable = true + this.$refs.DailyInspectionOrderExeDrawer.SWbuttonDistable = true + } else if (record.status === '5') { + this.$refs.DailyInspectionOrderExeDrawer.buttonDistable = true + this.$refs.DailyInspectionOrderExeDrawer.revocationDistable = false + this.$refs.DailyInspectionOrderExeDrawer.SWbuttonDistable = true + } else if (record.status === '6') { + this.$refs.DailyInspectionOrderExeDrawer.buttonDistable = true + this.$refs.DailyInspectionOrderExeDrawer.revocationDistable = true + this.$refs.DailyInspectionOrderExeDrawer.SWbuttonDistable = true + } + }, + + onSelectChange(selectionRows) { + this.selectionRows = selectionRows; + }, + + handleOrderIssue(record) { + const that = this; + requestPut(that.url.edit, { id: record.id, status: '2' }).then((res) => { + if (res.success) { + that.$message.success("宸ュ崟涓嬪彂鎴愬姛锛�") + that.loadData() + } else { + that.$message.warning("宸ュ崟涓嬪彂澶辫触锛�") + } + }) + }, + //鎾ゅ洖 + handleOrderReset(record) { + const that = this; + requestPut(that.url.edit, { id: record.id, status: '1' }).then((res) => { + if (res.success) { + that.$message.success("宸ュ崟鎾ゅ洖鎴愬姛锛�") + that.loadData() + } else { + that.$message.warning("宸ュ崟鎾ゅ洖澶辫触锛�") + } + }) + }, + handleOrderGet(record) { + const that = this; + requestPut(that.url.orderGet, { id: record.id, status: '3' }).then((res) => { + if (res.success) { + that.$message.success("宸ュ崟棰嗗彇鎴愬姛锛�") + that.loadData() + } else { + that.$message.warning("宸ュ崟棰嗗彇澶辫触锛�") + } + }) + }, + //缁翠慨纭 + handleOrderRepairConfirm(record) { + const that = this; + requestPut(that.url.edit, { id: record.id, status: '6' }).then((res) => { + if (res.success) { + that.$message.success("宸ュ崟瀹屽伐鎴愬姛锛�") + that.loadData() + } else { + that.$message.warning("宸ュ崟瀹屽伐澶辫触锛�") + } + }) + }, + + //鎭㈠ + handleOrderRecover(record) { + const that = this; + requestPut(that.url.edit, { id: record.id, status: '2' }).then((res) => { + if (res.success) { + that.$message.success("宸ュ崟鎭㈠鎴愬姛锛�") + that.loadData() + } else { + that.$message.warning("宸ュ崟鎭㈠澶辫触锛�") + } + }) + }, + + //棰勮棰滆壊 + tableRowClass(record, index) { + if (("1" == record.status || "2" == record.status) && "1鏃�" == record.inspectionCycleName) { + if (record.redWarningTime < record.currentDateTime) { + return 'error' + } + } + }, + clearList(){ + this.dataSource=[] + this.selectedRowKeys=[] + this.ipagination.current = 1 + } + + } +} +</script> +<style> +@import '~@assets/less/common.less'; +.frozenRowClass { + color: #c9c9c9; + font-weight: bold; +} +.success { + color: green; +} +.error { + color: red; + font-weight: bold; +} +.yellow { + color: rgba(255, 255, 0, 0.443); + font-weight: bold; +} +.fontweight { + font-weight: bold; +} + +.ant-table-tbody .red { + background-color: red !important; +} +</style> \ No newline at end of file diff --git a/src/views/eam/modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer.vue b/src/views/eam/modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer.vue index 24095c1..1c5c156 100644 --- a/src/views/eam/modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer.vue +++ b/src/views/eam/modules/equipmentNew/EquipmentResume/EquipmentResumeDrawer.vue @@ -154,7 +154,7 @@ </div> </a-tab-pane> <a-tab-pane - tab='妫�瀹氳褰�' + tab='閴村畾璁板綍' key="6" > <div -- Gitblit v1.9.3