已重命名1个文件
已添加1个文件
已修改3个文件
已删除1个文件
| | |
| | | </div> |
| | | <!-- tableåºå-end --> |
| | | |
| | | <a-tabs v-model="activeTabKey"> |
| | | <a-tabs v-model="activeTabKey" @change="handleTabChange"> |
| | | <a-tab-pane tab="ä¿å
»æ å" :key="1"> |
| | | <eam-maintenance-standard-list ref="tabPaneTableListRef" :isDisplayOperation="false"/> |
| | | <eam-maintenance-standard-list ref="tabPaneTableListRef1" :isDisplayOperation="false"/> |
| | | </a-tab-pane> |
| | | <a-tab-pane tab="维修工å" :key="2"> |
| | | <eam-repair-order-list ref="tabPaneTableListRef2" :isDisplayOperation="false"/> |
| | | </a-tab-pane> |
| | | </a-tabs> |
| | | |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import '@/assets/less/TableExpand.less' |
| | | import EamEquipmentModal from './modules/EamEquipmentModal' |
| | | import { JeecgListMixin } from '@/mixins/JeecgListMixin' |
| | | import { getAction, templateXlsDownload } from '@api/manage' |
| | | import NameplateModal from '@views/eam/equipment/modules/NameplateModal.vue' |
| | | import { getSystemConfigValue } from '@api/api' |
| | | import ResumeDrawer from '@views/eam/equipment/modules/ResumeDrawer.vue' |
| | | import EamMaintenanceStandardList from '@views/eam/base/EamMaintenanceStandardList.vue' |
| | | import '@/assets/less/TableExpand.less' |
| | | import EamEquipmentModal from './modules/EamEquipmentModal' |
| | | import { JeecgListMixin } from '@/mixins/JeecgListMixin' |
| | | import { getAction, templateXlsDownload } from '@api/manage' |
| | | import NameplateModal from '@views/eam/equipment/modules/NameplateModal.vue' |
| | | import { getSystemConfigValue } from '@api/api' |
| | | import ResumeDrawer from '@views/eam/equipment/modules/ResumeDrawer.vue' |
| | | import EamMaintenanceStandardList from '@views/eam/base/EamMaintenanceStandardList.vue' |
| | | import EamRepairOrderList from '../repair/EamRepairOrderList' |
| | | |
| | | export default { |
| | | name: 'EamEquipmentList', |
| | | mixins: [JeecgListMixin], |
| | | components: { |
| | | EamMaintenanceStandardList, |
| | | ResumeDrawer, |
| | | NameplateModal, |
| | | EamEquipmentModal |
| | | }, |
| | | data() { |
| | | return { |
| | | description: '设å¤å°è´¦ç®¡ç页é¢', |
| | | // 表头 |
| | | columns: [ |
| | | { |
| | | title: '#', |
| | | dataIndex: '', |
| | | key: 'rowIndex', |
| | | width: 60, |
| | | align: 'center', |
| | | customRender: function(t, r, index) { |
| | | return parseInt(index) + 1 |
| | | }, |
| | | fixed: 'left' |
| | | }, |
| | | { |
| | | title: '设å¤ç¼å·', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'equipmentCode', |
| | | ellipsis: true, |
| | | fixed: 'left', |
| | | sorter: true |
| | | }, |
| | | { |
| | | title: '设å¤åç§°', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'equipmentName', |
| | | ellipsis: true, |
| | | fixed: 'left' |
| | | }, |
| | | { |
| | | title: 'å
³é®è®¾å¤æ è¯', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'equipmentImportance', |
| | | scopedSlots: { customRender: 'equipmentImportance' } |
| | | }, |
| | | { |
| | | title: 'èµäº§ç¶æ', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'assetStatus_dictText' |
| | | }, |
| | | { |
| | | title: 'ææ¯ç¶æ', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'technologyStatus_dictText' |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®ç¶æ', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'repairStatus_dictText' |
| | | }, |
| | | { |
| | | title: 'ä¿å
»ç¶æ', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'maintenanceStatus_dictText' |
| | | }, |
| | | { |
| | | title: 'æä½ç³»ç»', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'operationSystem' |
| | | }, |
| | | { |
| | | title: '使ç¨è½¦é´', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'orgId_dictText' |
| | | }, |
| | | { |
| | | title: '设å¤ç®¡çå', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'equipmentManager_dictText' |
| | | }, |
| | | { |
| | | title: '设å¤åç±»', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'equipmentCategory_dictText' |
| | | }, |
| | | { |
| | | title: '设å¤åå·', |
| | | align: 'center', |
| | | width: 200, |
| | | dataIndex: 'equipmentModel' |
| | | }, |
| | | { |
| | | title: '设å¤è§æ ¼', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'equipmentSpecification' |
| | | }, |
| | | { |
| | | title: 'ä¸»è½´è¿æ¥å°ºå¯¸', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'spindleConnectDimension' |
| | | }, |
| | | { |
| | | title: 'æ»åç', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'equipmentPower' |
| | | }, |
| | | { |
| | | title: 'å®è£
ä½ç½®', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'installationPosition' |
| | | }, |
| | | |
| | | { |
| | | title: 'ç«é¡¹å¡å·', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'cardNumber' |
| | | }, |
| | | { |
| | | title: 'åºåç¼å·', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'factoryNumber' |
| | | }, |
| | | { |
| | | title: 'æºåºåå®¶', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'manufacturingEnterprise' |
| | | }, |
| | | { |
| | | title: 'æ¥æºå½å®¶', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'originCountry' |
| | | }, |
| | | { |
| | | title: 'åºåæ¥æ', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'leaveFactoryDate' |
| | | }, |
| | | { |
| | | title: 'éªæ¶æ¥æ', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'acceptanceCheckDate' |
| | | }, |
| | | { |
| | | title: 'è´¨ä¿å¼å§æ¥æ', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'warrantyStartDate' |
| | | }, |
| | | { |
| | | title: 'è´¨ä¿ç»ææ¥æ', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'warrantyEndDate' |
| | | }, |
| | | { |
| | | title: 'æ¯å¦å®æ½MDC', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'mdcFlag', |
| | | scopedSlots: { customRender: 'mdcFlag' } |
| | | }, |
| | | { |
| | | title: 'ææ å·¥èºåæ°', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'processParametersFlag', |
| | | scopedSlots: { customRender: 'processParametersFlag' } |
| | | }, |
| | | { |
| | | title: 'ææ ç²¾åº¦åæ°', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'precisionParametersFlag', |
| | | scopedSlots: { customRender: 'precisionParametersFlag' } |
| | | }, |
| | | { |
| | | title: 'æ¯å¦ä¸ºç¹ç§è®¾å¤', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'specialEquipment', |
| | | scopedSlots: { customRender: 'specialEquipment' } |
| | | }, |
| | | { |
| | | title: 'éé', |
| | | align: 'center', |
| | | dataIndex: 'equipmentWeight' |
| | | }, |
| | | { |
| | | title: '设å¤ç«¯å£', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'equipmentPort' |
| | | }, |
| | | { |
| | | title: 'åæ æ°é', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'coordinateNum' |
| | | }, |
| | | { |
| | | title: 'å建人', |
| | | align: 'center', |
| | | dataIndex: 'createBy_dictText' |
| | | }, |
| | | { |
| | | title: 'å建æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'createTime' |
| | | }, |
| | | { |
| | | title: 'æ´æ°äºº', |
| | | align: 'center', |
| | | dataIndex: 'updateBy_dictText' |
| | | }, |
| | | { |
| | | title: 'æ´æ°æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'updateTime' |
| | | }, |
| | | { |
| | | title: '夿³¨', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'remark' |
| | | }, |
| | | { |
| | | title: 'æä½', |
| | | dataIndex: 'action', |
| | | align: 'center', |
| | | width: 150, |
| | | scopedSlots: { customRender: 'action' }, |
| | | fixed: 'right' |
| | | } |
| | | ], |
| | | url: { |
| | | list: '/eam/equipment/list', |
| | | delete: '/eam/equipment/delete', |
| | | deleteBatch: '/eam/equipment/deleteBatch', |
| | | exportXlsUrl: 'eam/equipment/exportXls', |
| | | importExcelUrl: 'eam/equipment/importExcel', |
| | | loadProductionOptions: '/mdc/mdcProduction/loadProductionTreeOptions', |
| | | templateXlsDownloadUrl: '导å
¥æ¨¡æ¿/设å¤å°è´¦å¯¼å
¥æ¨¡æ¿_v1.0.xlsx' |
| | | }, |
| | | treeData: [], |
| | | printedRows: [], |
| | | activeTabKey: 1, |
| | | appHomeUrl: '' |
| | | } |
| | | }, |
| | | computed: { |
| | | importExcelUrl: function() { |
| | | return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}` |
| | | } |
| | | }, |
| | | created() { |
| | | this.loadAllProductionTree() |
| | | this.loadAppHomeUrlConfigValue() |
| | | }, |
| | | methods: { |
| | | loadAllProductionTree() { |
| | | //å 载车é´éæ©æ |
| | | getAction(this.url.loadProductionOptions).then(res => { |
| | | if (res.success) { |
| | | this.treeData = [...res.result] |
| | | } else { |
| | | that.$message.warning(res.message) |
| | | } |
| | | }) |
| | | export default { |
| | | name: 'EamEquipmentList', |
| | | mixins: [JeecgListMixin], |
| | | components: { |
| | | EamRepairOrderList, |
| | | EamMaintenanceStandardList, |
| | | ResumeDrawer, |
| | | NameplateModal, |
| | | EamEquipmentModal |
| | | }, |
| | | |
| | | /** |
| | | * å¼å¯éçå¼¹çª |
| | | * @param recordArray è¡¨æ ¼è¡ä¿¡æ¯éå |
| | | */ |
| | | handleOpenNameplateModal(recordArray) { |
| | | this.printedRows = recordArray |
| | | this.$refs.nameplateModalRef.httpUrl = this.appHomeUrl |
| | | this.$refs.nameplateModalRef.visible = true |
| | | }, |
| | | |
| | | /** |
| | | * å¼å¯å±¥åæ½å± |
| | | * @param record è¡¨æ ¼è¡ä¿¡æ¯ |
| | | */ |
| | | handleOpenResumeDrawer(record) { |
| | | this.$refs.resumeDrawerRef.visible = true |
| | | }, |
| | | |
| | | /** |
| | | * èªå®ä¹è®¾å¤å°è´¦è¡¨æ ¼è¡ |
| | | * @param record è¡¨æ ¼è¡ä¿¡æ¯ |
| | | * @returns {{style: {cursor: string}, on: {click: *}}} æ ·å¼å¯¹è±¡ä¸äºä»¶æ¹æ³ |
| | | */ |
| | | customTableRow(record) { |
| | | data() { |
| | | return { |
| | | style: { |
| | | cursor: 'pointer' |
| | | }, |
| | | on: { |
| | | click: () => { |
| | | this.onSelectChange([record.id]) |
| | | description: '设å¤å°è´¦ç®¡ç页é¢', |
| | | // 表头 |
| | | columns: [ |
| | | { |
| | | title: '#', |
| | | dataIndex: '', |
| | | key: 'rowIndex', |
| | | width: 60, |
| | | align: 'center', |
| | | customRender: function(t, r, index) { |
| | | return parseInt(index) + 1 |
| | | }, |
| | | fixed: 'left' |
| | | }, |
| | | { |
| | | title: '设å¤ç¼å·', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'equipmentCode', |
| | | ellipsis: true, |
| | | fixed: 'left', |
| | | sorter: true |
| | | }, |
| | | { |
| | | title: '设å¤åç§°', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'equipmentName', |
| | | ellipsis: true, |
| | | fixed: 'left' |
| | | }, |
| | | { |
| | | title: 'å
³é®è®¾å¤æ è¯', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'equipmentImportance', |
| | | scopedSlots: { customRender: 'equipmentImportance' } |
| | | }, |
| | | { |
| | | title: 'èµäº§ç¶æ', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'assetStatus_dictText' |
| | | }, |
| | | { |
| | | title: 'ææ¯ç¶æ', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'technologyStatus_dictText' |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®ç¶æ', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'repairStatus_dictText' |
| | | }, |
| | | { |
| | | title: 'ä¿å
»ç¶æ', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'maintenanceStatus_dictText' |
| | | }, |
| | | { |
| | | title: 'æä½ç³»ç»', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'operationSystem' |
| | | }, |
| | | { |
| | | title: '使ç¨è½¦é´', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'orgId_dictText' |
| | | }, |
| | | { |
| | | title: '设å¤ç®¡çå', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'equipmentManager_dictText' |
| | | }, |
| | | { |
| | | title: '设å¤åç±»', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'equipmentCategory_dictText' |
| | | }, |
| | | { |
| | | title: '设å¤åå·', |
| | | align: 'center', |
| | | width: 200, |
| | | dataIndex: 'equipmentModel' |
| | | }, |
| | | { |
| | | title: '设å¤è§æ ¼', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'equipmentSpecification' |
| | | }, |
| | | { |
| | | title: 'ä¸»è½´è¿æ¥å°ºå¯¸', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'spindleConnectDimension' |
| | | }, |
| | | { |
| | | title: 'æ»åç', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'equipmentPower' |
| | | }, |
| | | { |
| | | title: 'å®è£
ä½ç½®', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'installationPosition' |
| | | }, |
| | | |
| | | { |
| | | title: 'ç«é¡¹å¡å·', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'cardNumber' |
| | | }, |
| | | { |
| | | title: 'åºåç¼å·', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'factoryNumber' |
| | | }, |
| | | { |
| | | title: 'æºåºåå®¶', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'manufacturingEnterprise' |
| | | }, |
| | | { |
| | | title: 'æ¥æºå½å®¶', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'originCountry' |
| | | }, |
| | | { |
| | | title: 'åºåæ¥æ', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'leaveFactoryDate' |
| | | }, |
| | | { |
| | | title: 'éªæ¶æ¥æ', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'acceptanceCheckDate' |
| | | }, |
| | | { |
| | | title: 'è´¨ä¿å¼å§æ¥æ', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'warrantyStartDate' |
| | | }, |
| | | { |
| | | title: 'è´¨ä¿ç»ææ¥æ', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'warrantyEndDate' |
| | | }, |
| | | { |
| | | title: 'æ¯å¦å®æ½MDC', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'mdcFlag', |
| | | scopedSlots: { customRender: 'mdcFlag' } |
| | | }, |
| | | { |
| | | title: 'ææ å·¥èºåæ°', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'processParametersFlag', |
| | | scopedSlots: { customRender: 'processParametersFlag' } |
| | | }, |
| | | { |
| | | title: 'ææ ç²¾åº¦åæ°', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'precisionParametersFlag', |
| | | scopedSlots: { customRender: 'precisionParametersFlag' } |
| | | }, |
| | | { |
| | | title: 'æ¯å¦ä¸ºç¹ç§è®¾å¤', |
| | | align: 'center', |
| | | width: 120, |
| | | dataIndex: 'specialEquipment', |
| | | scopedSlots: { customRender: 'specialEquipment' } |
| | | }, |
| | | { |
| | | title: 'éé', |
| | | align: 'center', |
| | | dataIndex: 'equipmentWeight' |
| | | }, |
| | | { |
| | | title: '设å¤ç«¯å£', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'equipmentPort' |
| | | }, |
| | | { |
| | | title: 'åæ æ°é', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'coordinateNum' |
| | | }, |
| | | { |
| | | title: 'å建人', |
| | | align: 'center', |
| | | dataIndex: 'createBy_dictText' |
| | | }, |
| | | { |
| | | title: 'å建æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'createTime' |
| | | }, |
| | | { |
| | | title: 'æ´æ°äºº', |
| | | align: 'center', |
| | | dataIndex: 'updateBy_dictText' |
| | | }, |
| | | { |
| | | title: 'æ´æ°æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'updateTime' |
| | | }, |
| | | { |
| | | title: '夿³¨', |
| | | align: 'center', |
| | | width: 100, |
| | | dataIndex: 'remark' |
| | | }, |
| | | { |
| | | title: 'æä½', |
| | | dataIndex: 'action', |
| | | align: 'center', |
| | | width: 150, |
| | | scopedSlots: { customRender: 'action' }, |
| | | fixed: 'right' |
| | | } |
| | | } |
| | | ], |
| | | url: { |
| | | list: '/eam/equipment/list', |
| | | delete: '/eam/equipment/delete', |
| | | deleteBatch: '/eam/equipment/deleteBatch', |
| | | exportXlsUrl: 'eam/equipment/exportXls', |
| | | importExcelUrl: 'eam/equipment/importExcel', |
| | | loadProductionOptions: '/mdc/mdcProduction/loadProductionTreeOptions', |
| | | templateXlsDownloadUrl: '导å
¥æ¨¡æ¿/设å¤å°è´¦å¯¼å
¥æ¨¡æ¿_v1.0.xlsx' |
| | | }, |
| | | treeData: [], |
| | | printedRows: [], |
| | | activeTabKey: 1, |
| | | appHomeUrl: '' |
| | | } |
| | | }, |
| | | |
| | | /** |
| | | * å 载页ç¾è¡¨æ ¼æ°æ® |
| | | * @param id 设å¤å°è´¦è¡è®°å½Id |
| | | */ |
| | | loadTabPaneTableData(id) { |
| | | this.$refs.tabPaneTableListRef.queryParam.equipmentId = id |
| | | this.$refs.tabPaneTableListRef.loadData(1) |
| | | computed: { |
| | | importExcelUrl: function() { |
| | | return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}` |
| | | } |
| | | }, |
| | | |
| | | /** |
| | | * 设å¤å°è´¦è¡¨æ ¼å¤éæ¡ç¶ææ¹åæ¶è§¦å |
| | | * @param selectedRowKeys 已鿩çrowKeyéå |
| | | * @param selectionRows å½åå页ä¸å·²éæ©çè¡ä¿¡æ¯éå |
| | | */ |
| | | onSelectChange(selectedRowKeys, selectionRows) { |
| | | this.selectedRowKeys = selectedRowKeys |
| | | this.selectionRows = selectionRows |
| | | this.$refs.tabPaneTableListRef.dataSource = [] |
| | | this.$refs.tabPaneTableListRef.onClearSelected() |
| | | if (selectedRowKeys.length === 1) this.loadTabPaneTableData(selectedRowKeys[0]) |
| | | created() { |
| | | this.loadAllProductionTree() |
| | | this.loadAppHomeUrlConfigValue() |
| | | }, |
| | | methods: { |
| | | loadAllProductionTree() { |
| | | //å 载车é´éæ©æ |
| | | getAction(this.url.loadProductionOptions).then(res => { |
| | | if (res.success) { |
| | | this.treeData = [...res.result] |
| | | } else { |
| | | that.$message.warning(res.message) |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | handleTemplateXlsDownload() { |
| | | templateXlsDownload(this.url.templateXlsDownloadUrl) |
| | | }, |
| | | /** |
| | | * å¼å¯éçå¼¹çª |
| | | * @param recordArray è¡¨æ ¼è¡ä¿¡æ¯éå |
| | | */ |
| | | handleOpenNameplateModal(recordArray) { |
| | | this.printedRows = recordArray |
| | | this.$refs.nameplateModalRef.httpUrl = this.appHomeUrl |
| | | this.$refs.nameplateModalRef.visible = true |
| | | }, |
| | | |
| | | loadAppHomeUrlConfigValue() { |
| | | let params = { settingKey: 'app_home_url' } |
| | | getSystemConfigValue(params).then(res => { |
| | | if (res.success) { |
| | | this.appHomeUrl = res.result.settingValue |
| | | /** |
| | | * å¼å¯å±¥åæ½å± |
| | | * @param record è¡¨æ ¼è¡ä¿¡æ¯ |
| | | */ |
| | | handleOpenResumeDrawer(record) { |
| | | this.$refs.resumeDrawerRef.visible = true |
| | | }, |
| | | |
| | | /** |
| | | * èªå®ä¹è®¾å¤å°è´¦è¡¨æ ¼è¡ |
| | | * @param record è¡¨æ ¼è¡ä¿¡æ¯ |
| | | * @returns {{style: {cursor: string}, on: {click: *}}} æ ·å¼å¯¹è±¡ä¸äºä»¶æ¹æ³ |
| | | */ |
| | | customTableRow(record) { |
| | | return { |
| | | style: { |
| | | cursor: 'pointer' |
| | | }, |
| | | on: { |
| | | click: () => { |
| | | this.onSelectChange([record.id]) |
| | | } |
| | | } |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | /** |
| | | * é¡µç¾æ¹åæ¶è§¦å |
| | | * @param activeTabKey å½åæ¿æ´»ç页ç¾key |
| | | */ |
| | | handleTabChange(activeTabKey) { |
| | | if (this.selectedRowKeys.length !== 1) return |
| | | this.$nextTick(() => this.loadTabPaneTableData(this.selectedRowKeys[0])) |
| | | }, |
| | | |
| | | /** |
| | | * å 载页ç¾è¡¨æ ¼æ°æ® |
| | | * @param id 设å¤å°è´¦è¡è®°å½Id |
| | | */ |
| | | loadTabPaneTableData(id) { |
| | | this.$refs['tabPaneTableListRef' + this.activeTabKey].queryParam.equipmentId = id |
| | | this.$refs['tabPaneTableListRef' + this.activeTabKey].loadData(1) |
| | | }, |
| | | |
| | | /** |
| | | * 设å¤å°è´¦è¡¨æ ¼å¤éæ¡ç¶ææ¹åæ¶è§¦å |
| | | * @param selectedRowKeys 已鿩çrowKeyéå |
| | | * @param selectionRows å½åå页ä¸å·²éæ©çè¡ä¿¡æ¯éå |
| | | */ |
| | | onSelectChange(selectedRowKeys, selectionRows) { |
| | | this.selectedRowKeys = selectedRowKeys |
| | | this.selectionRows = selectionRows |
| | | this.$refs['tabPaneTableListRef' + this.activeTabKey].dataSource = [] |
| | | this.$refs['tabPaneTableListRef' + this.activeTabKey].onClearSelected() |
| | | if (selectedRowKeys.length === 1) this.loadTabPaneTableData(selectedRowKeys[0]) |
| | | }, |
| | | |
| | | handleTemplateXlsDownload() { |
| | | templateXlsDownload(this.url.templateXlsDownloadUrl) |
| | | }, |
| | | |
| | | loadAppHomeUrlConfigValue() { |
| | | let params = { settingKey: 'app_home_url' } |
| | | getSystemConfigValue(params).then(res => { |
| | | if (res.success) { |
| | | this.appHomeUrl = res.result.settingValue |
| | | } |
| | | }) |
| | | } |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | <style scoped> |
| | | @import '~@assets/less/common.less'; |
| | | @import '~@assets/less/common.less'; |
| | | </style> |
| | |
| | | <a-card :bordered="false"> |
| | | |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div class="table-page-search-wrapper"> |
| | | <div class="table-page-search-wrapper" v-if="isDisplayOperation"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | | <a-row :gutter="24"> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | |
| | | <a-input placeholder="请è¾å
¥å·¥åç¼å·" v-model="queryParam.repairCode"></a-input> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <a-form-item label="设å¤ç¼å·"> |
| | | <!--<a-input placeholder="请è¾å
¥è®¾å¤ç¼å·" v-model="queryParam.equipmentId"/>--> |
| | | <lx-search-equipment-select placeholder="请è¾å
¥è®¾å¤ç¼å·æåç§°æç´¢" v-model="queryParam.equipmentId"/> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <a-form-item label="åæ®ç¶æ"> |
| | | <a-select placeholder="è¯·éæ©åæ®ç¶æ" v-model="queryParam.repairStatus" allow-clear> |
| | | <a-select-option v-for="item in report_repair_status_list" :key="item.value">{{ item.label }} |
| | | </a-select-option> |
| | | </a-select> |
| | | </a-form-item> |
| | | </a-col> |
| | | <template v-if="toggleSearchStatus"> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <a-form-item label="设å¤ç¼å·"> |
| | | <lx-search-equipment-select placeholder="请è¾å
¥è®¾å¤ç¼å·æåç§°æç´¢" v-model="queryParam.equipmentId"/> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <a-form-item label="ç»´ä¿®ç¶æ"> |
| | | <a-input placeholder="请è¾å
¥ç»´ä¿®ç¶æ" v-model="queryParam.repairStatus"></a-input> |
| | | </a-form-item> |
| | | </a-col> |
| | | |
| | | </template> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> |
| | | <a-button type="primary" @click="searchQuery" icon="search">æ¥è¯¢</a-button> |
| | | <a-button @click="searchReset" icon="reload" style="margin-left: 8px">éç½®</a-button> |
| | | <a @click="handleToggleSearch" style="margin-left: 8px"> |
| | | {{ toggleSearchStatus ? 'æ¶èµ·' : 'å±å¼' }} |
| | | <a-icon :type="toggleSearchStatus ? 'up' : 'down'"/> |
| | | </a> |
| | | <!--<a @click="handleToggleSearch" style="margin-left: 8px">--> |
| | | <!--{{ toggleSearchStatus ? 'æ¶èµ·' : 'å±å¼' }}--> |
| | | <!--<a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>--> |
| | | <!--</a>--> |
| | | </span> |
| | | </a-col> |
| | | |
| | |
| | | </div> |
| | | |
| | | <!-- æä½æé®åºå --> |
| | | <div class="table-operator"> |
| | | <a-button @click="handleAdd" type="primary" icon="plus">æ°å¢</a-button> |
| | | <div class="table-operator" v-if="isDisplayOperation"> |
| | | <a-button @click="handleOpenReceiveFaultModal" type="primary" icon="plus">é¢å</a-button> |
| | | <a-button type="primary" icon="download" @click="handleExportXls('维修工å')">导åº</a-button> |
| | | <a-dropdown v-if="selectedRowKeys.length > 0"> |
| | | <a-menu slot="overlay"> |
| | |
| | | |
| | | <!-- tableåºå-begin --> |
| | | <div> |
| | | <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> |
| | | <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;" v-if="isDisplayOperation"> |
| | | <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> |
| | |
| | | > |
| | | |
| | | <span slot="action" slot-scope="text, record"> |
| | | <a @click="handleEdit(record)">ç¼è¾</a> |
| | | <a @click="handleOpenApplySparePartsModal(record)">ç³è¯·å¤ä»¶</a> |
| | | |
| | | <a-divider type="vertical"/> |
| | | <a-dropdown> |
| | | <a class="ant-dropdown-link">æ´å¤ <a-icon type="down"/></a> |
| | | <a-menu slot="overlay"> |
| | | <a-menu-item> |
| | | <a-popconfirm title="ç¡®å®å é¤å?" @confirm="() => handleDelete(record.id)"> |
| | | <a>å é¤</a> |
| | | </a-popconfirm> |
| | | </a-menu-item> |
| | | </a-menu> |
| | | </a-dropdown> |
| | | |
| | | <a @click="handleOpenRepairCompletedModal(record)">å®æç»´ä¿®</a> |
| | | |
| | | <!--<a @click="handleEdit(record)">ç¼è¾</a>--> |
| | | |
| | | <!--<a-divider type="vertical"/>--> |
| | | <!--<a-dropdown>--> |
| | | <!--<a class="ant-dropdown-link">æ´å¤ <a-icon type="down"/></a>--> |
| | | <!--<a-menu slot="overlay">--> |
| | | <!--<a-menu-item>--> |
| | | <!--<a-popconfirm title="ç¡®å®å é¤å?" @confirm="() => handleDelete(record.id)">--> |
| | | <!--<a>å é¤</a>--> |
| | | <!--</a-popconfirm>--> |
| | | <!--</a-menu-item>--> |
| | | <!--</a-menu>--> |
| | | <!--</a-dropdown>--> |
| | | </span> |
| | | |
| | | </a-table> |
| | | </div> |
| | | <!-- tableåºå-end --> |
| | | |
| | | <!-- 表ååºå --> |
| | | <eamRepairOrder-modal ref="modalForm" @ok="modalFormOk"></eamRepairOrder-modal> |
| | | <receive-fault-modal ref="receiveFaultModalRef" @ok="loadData"/> |
| | | </a-card> |
| | | </template> |
| | | |
| | | <script> |
| | | import '@/assets/less/TableExpand.less' |
| | | import EamRepairOrderModal from './modules/EamRepairOrderModal' |
| | | import { JeecgListMixin } from '@/mixins/JeecgListMixin' |
| | | import LxSearchEquipmentSelect from '@views/eam/equipment/modules/LxSearchEquipmentSelect.vue' |
| | | import '@/assets/less/TableExpand.less' |
| | | import { JeecgListMixin } from '@/mixins/JeecgListMixin' |
| | | import ReceiveFaultModal from './modules/EamRepairOrderList/ReceiveFaultModal' |
| | | import { ajaxGetDictItems, getDictItemsFromCache } from '@/api/api' |
| | | import LxSearchEquipmentSelect from '../equipment/modules/LxSearchEquipmentSelect' |
| | | |
| | | export default { |
| | | name: 'EamRepairOrderList', |
| | | mixins: [JeecgListMixin], |
| | | components: { |
| | | LxSearchEquipmentSelect, |
| | | EamRepairOrderModal |
| | | }, |
| | | data() { |
| | | return { |
| | | description: '维修工å管ç页é¢', |
| | | // 表头 |
| | | columns: [ |
| | | { |
| | | title: 'å·¥åç¼å·', |
| | | align: 'center', |
| | | dataIndex: 'repairCode', |
| | | width: 200, |
| | | fixed: 'left' |
| | | }, |
| | | // { |
| | | // title: 'æ¥ä¿®ç¼å·', |
| | | // align: 'center', |
| | | // dataIndex: 'reportId', |
| | | // width: 200, |
| | | // fixed: 'left' |
| | | // }, |
| | | { |
| | | title: '设å¤ç¼å·', |
| | | align: 'center', |
| | | dataIndex: 'equipmentId_dictText', |
| | | width: 200, |
| | | fixed: 'left' |
| | | }, |
| | | { |
| | | title: 'ç¶æ', |
| | | align: 'center', |
| | | dataIndex: 'repairStatus_dictText', |
| | | fixed: 'left', |
| | | width: 100 |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®å¼å§æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'actualStartTime', |
| | | width: 200 |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®ç»ææ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'actualEndTime', |
| | | width: 200 |
| | | }, |
| | | { |
| | | title: 'æ
éåå ', |
| | | align: 'center', |
| | | dataIndex: 'faultReason' |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®ç»ææè¿°', |
| | | align: 'center', |
| | | dataIndex: 'repairDescription', |
| | | width: 300 |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®è´è´£äºº', |
| | | align: 'center', |
| | | dataIndex: 'repairer', |
| | | width: 100 |
| | | }, |
| | | // { |
| | | // title: 'æ¯å¦å§å¤', |
| | | // align: 'center', |
| | | // dataIndex: 'outsourcedFlag', |
| | | // width: 100 |
| | | // }, |
| | | // { |
| | | // title: 'å§å¤ç»´ä¿®æè¿°', |
| | | // align: 'center', |
| | | // dataIndex: 'outsourcedRepairDecription', |
| | | // width: 300 |
| | | // }, |
| | | // { |
| | | // title: 'å§å¤ç»´ä¿®å¼å§æ¶é´', |
| | | // align: 'center', |
| | | // dataIndex: 'outsourcedStartTime', |
| | | // width: 200 |
| | | // }, |
| | | // { |
| | | // title: 'å§å¤ç»´ä¿®ç»ææ¶é´', |
| | | // align: 'center', |
| | | // dataIndex: 'outsourcedEndTime', |
| | | // width: 200 |
| | | // }, |
| | | // { |
| | | // title: 'å§å¤è´è´£äºº', |
| | | // align: 'center', |
| | | // dataIndex: 'outsourcedPerson', |
| | | // width: 100 |
| | | // }, |
| | | { |
| | | title: 'ç»´ä¿®å¾ç', |
| | | align: 'center', |
| | | dataIndex: 'imageFiles', |
| | | width: 100 |
| | | }, |
| | | { |
| | | title: 'æä½', |
| | | dataIndex: 'action', |
| | | align: 'center', |
| | | scopedSlots: { customRender: 'action' }, |
| | | fixed: 'right', |
| | | width: 150 |
| | | export default { |
| | | name: 'EamRepairOrderList', |
| | | mixins: [JeecgListMixin], |
| | | components: { |
| | | LxSearchEquipmentSelect, |
| | | ReceiveFaultModal |
| | | }, |
| | | props:{ |
| | | isDisplayOperation:{ |
| | | type:Boolean, |
| | | default:true |
| | | } |
| | | }, |
| | | data() { |
| | | return { |
| | | description: '维修工å管ç页é¢', |
| | | disableMixinCreated: true, |
| | | // 表头 |
| | | columns: [ |
| | | { |
| | | title: 'å·¥åç¼å·', |
| | | align: 'center', |
| | | dataIndex: 'repairCode', |
| | | width: 200, |
| | | fixed: 'left' |
| | | }, |
| | | // { |
| | | // title: 'æ¥ä¿®ç¼å·', |
| | | // align: 'center', |
| | | // dataIndex: 'reportId', |
| | | // width: 200, |
| | | // fixed: 'left' |
| | | // }, |
| | | { |
| | | title: '设å¤ç¼å·', |
| | | align: 'center', |
| | | dataIndex: 'equipmentId_dictText', |
| | | width: 200, |
| | | fixed: 'left' |
| | | }, |
| | | { |
| | | title: 'ç¶æ', |
| | | align: 'center', |
| | | dataIndex: 'repairStatus_dictText', |
| | | fixed: 'left', |
| | | width: 100 |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®å¼å§æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'actualStartTime', |
| | | width: 200 |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®ç»ææ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'actualEndTime', |
| | | width: 200 |
| | | }, |
| | | { |
| | | title: 'æ
éåå ', |
| | | align: 'center', |
| | | dataIndex: 'faultReason', |
| | | width: 150 |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®ç»ææè¿°', |
| | | align: 'center', |
| | | dataIndex: 'repairDescription', |
| | | width: 300 |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®å¾ç', |
| | | align: 'center', |
| | | dataIndex: 'imageFiles', |
| | | width: 100 |
| | | }, |
| | | { |
| | | title: 'ç»´ä¿®è´è´£äºº', |
| | | align: 'center', |
| | | dataIndex: 'repairer' |
| | | }, |
| | | // { |
| | | // title: 'æ¯å¦å§å¤', |
| | | // align: 'center', |
| | | // dataIndex: 'outsourcedFlag', |
| | | // width: 100 |
| | | // }, |
| | | // { |
| | | // title: 'å§å¤ç»´ä¿®æè¿°', |
| | | // align: 'center', |
| | | // dataIndex: 'outsourcedRepairDecription', |
| | | // width: 300 |
| | | // }, |
| | | // { |
| | | // title: 'å§å¤ç»´ä¿®å¼å§æ¶é´', |
| | | // align: 'center', |
| | | // dataIndex: 'outsourcedStartTime', |
| | | // width: 200 |
| | | // }, |
| | | // { |
| | | // title: 'å§å¤ç»´ä¿®ç»ææ¶é´', |
| | | // align: 'center', |
| | | // dataIndex: 'outsourcedEndTime', |
| | | // width: 200 |
| | | // }, |
| | | // { |
| | | // title: 'å§å¤è´è´£äºº', |
| | | // align: 'center', |
| | | // dataIndex: 'outsourcedPerson', |
| | | // width: 100 |
| | | // }, |
| | | ], |
| | | report_repair_status_list: [], |
| | | url: { |
| | | list: '/eam/eamRepairOrder/list', |
| | | delete: '/eam/eamRepairOrder/delete', |
| | | deleteBatch: '/eam/eamRepairOrder/deleteBatch', |
| | | exportXlsUrl: 'eam/eamRepairOrder/exportXls' |
| | | } |
| | | ], |
| | | url: { |
| | | list: '/eam/eamRepairOrder/list', |
| | | delete: '/eam/eamRepairOrder/delete', |
| | | deleteBatch: '/eam/eamRepairOrder/deleteBatch', |
| | | exportXlsUrl: 'eam/eamRepairOrder/exportXls', |
| | | } |
| | | }, |
| | | computed: { |
| | | importExcelUrl: function() { |
| | | return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}` |
| | | } |
| | | }, |
| | | created() { |
| | | if (!this.isDisplayOperation) { |
| | | return |
| | | } |
| | | this.initDictData('report_repair_status') |
| | | const operationColumn = { |
| | | title: 'æä½', |
| | | dataIndex: 'action', |
| | | align: 'center', |
| | | scopedSlots: { customRender: 'action' } |
| | | } |
| | | this.columns = [...this.columns, operationColumn] |
| | | this.loadData(1) |
| | | }, |
| | | methods: { |
| | | /** |
| | | * è·åæ°æ®åå
¸å¼ |
| | | * @param dictCode æ°æ®åå
¸å¯¹åºè®°å½ç¼ç |
| | | */ |
| | | initDictData(dictCode) { |
| | | // //ä¼å
ä»ç¼åä¸è¯»ååå
¸é
ç½® |
| | | if (getDictItemsFromCache(dictCode)) { |
| | | this[dictCode + '_list'] = getDictItemsFromCache(dictCode) |
| | | return |
| | | } |
| | | //æ ¹æ®åå
¸Code, åå§ååå
¸æ°ç» |
| | | ajaxGetDictItems(dictCode, null).then((res) => { |
| | | if (res.success) { |
| | | this[dictCode + '_list'] = res.result |
| | | return |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | // å¼å¯é¢åæ
éä¿ä¿®åå¼¹çª |
| | | handleOpenReceiveFaultModal() { |
| | | this.$refs.receiveFaultModalRef.visible = true |
| | | this.$refs.receiveFaultModalRef.loadData() |
| | | }, |
| | | |
| | | /** |
| | | * å¼å¯ç³è¯·å¤ä»¶å¼¹çª |
| | | * @param record è¡¨æ ¼è¡ä¿¡æ¯ |
| | | */ |
| | | handleOpenApplySparePartsModal(record) { |
| | | |
| | | }, |
| | | |
| | | /** |
| | | * å¼å¯å®æç»´ä¿®å¼¹çª |
| | | * @param record è¡¨æ ¼è¡ä¿¡æ¯ |
| | | */ |
| | | handleOpenRepairCompletedModal(record) { |
| | | |
| | | } |
| | | } |
| | | }, |
| | | computed: { |
| | | importExcelUrl: function() { |
| | | return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}` |
| | | } |
| | | }, |
| | | methods: {} |
| | | } |
| | | } |
| | | </script> |
| | | <style scoped> |
| | | @import '~@assets/less/common.less'; |
| | | @import '~@assets/less/common.less'; |
| | | </style> |
| | |
| | | <a-row :gutter="24"> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <a-form-item label="设å¤ç¼å·"> |
| | | <a-input placeholder="请è¾å
¥è®¾å¤ç¼å·" v-model="queryParam.equipmentId"/> |
| | | <!--<a-input placeholder="请è¾å
¥è®¾å¤ç¼å·" v-model="queryParam.equipmentId"/>--> |
| | | <lx-search-equipment-select placeholder="请è¾å
¥è®¾å¤ç¼å·æåç§°æç´¢" v-model="queryParam.equipmentId"/> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24" v-if="isDisplayOperation"> |
| | | <a-form-item label="åæ®ç¶æ"> |
| | | <a-select placeholder="è¯·éæ©åæ®ç¶æ" v-model="queryParam.reportStatus" allow-clear> |
| | | <a-select-option v-for="item in report_repair_status_list" :key="item.value">{{ item.label }} |
| | |
| | | </div> |
| | | |
| | | <!-- æä½æé®åºå --> |
| | | <div class="table-operator"> |
| | | <div class="table-operator" v-if="isDisplayOperation"> |
| | | <a-button @click="handleAdd" type="primary" icon="plus">æ°å¢</a-button> |
| | | <a-button type="primary" icon="download" @click="handleExportXls('æ
éæ¥ä¿®')">导åº</a-button> |
| | | <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" |
| | |
| | | |
| | | <!-- tableåºå-begin --> |
| | | <div> |
| | | <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;"> |
| | | <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;" v-if="isDisplayOperation"> |
| | | <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> |
| | |
| | | :pagination="ipagination" |
| | | :loading="loading" |
| | | class="j-table-force-nowrap" |
| | | :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}" |
| | | :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange,type:isDisplayOperation?'checkbox':'radio'}" |
| | | @change="handleTableChange"> |
| | | |
| | | <template slot="imageFiles" slot-scope="text, record" v-if="text"> |
| | |
| | | <a-popconfirm title="ç¡®å®ä½åºå?" @confirm="() => handleDelete(record.id)"> |
| | | <a>ä½åº</a> |
| | | </a-popconfirm> |
| | | <!-- <a-dropdown>--> |
| | | <!-- <a class="ant-dropdown-link">æ´å¤ <a-icon type="down"/></a>--> |
| | | <!-- <a-menu slot="overlay">--> |
| | | <!-- <a-menu-item>--> |
| | | <!-- <a-popconfirm title="ç¡®å®å é¤å?" @confirm="() => handleDelete(record.id)">--> |
| | | <!-- <a>å é¤</a>--> |
| | | <!-- </a-popconfirm>--> |
| | | <!-- </a-menu-item>--> |
| | | <!-- </a-menu>--> |
| | | <!-- </a-dropdown>--> |
| | | </span> |
| | | |
| | | </a-table> |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import '@/assets/less/TableExpand.less' |
| | | import EamReportRepairModal from './modules/EamReportRepairModal' |
| | | import { JeecgListMixin } from '@/mixins/JeecgListMixin' |
| | | import LxSearchEquipmentSelect from '@views/eam/equipment/modules/LxSearchEquipmentSelect.vue' |
| | | import { ajaxGetDictItems, getDictItemsFromCache } from '@/api/api' |
| | | import ImagesPreviewModal from '@views/eam/repair/modules/ImagesPreviewModal.vue' |
| | | import { getAction } from '@/api/manage' |
| | | import '@/assets/less/TableExpand.less' |
| | | import EamReportRepairModal from './modules/EamReportRepairList/EamReportRepairModal' |
| | | import { JeecgListMixin } from '@/mixins/JeecgListMixin' |
| | | import LxSearchEquipmentSelect from '@views/eam/equipment/modules/LxSearchEquipmentSelect.vue' |
| | | import { ajaxGetDictItems, getDictItemsFromCache } from '@/api/api' |
| | | import ImagesPreviewModal from '@views/eam/repair/modules/ImagesPreviewModal.vue' |
| | | import { getAction } from '@/api/manage' |
| | | |
| | | |
| | | export default { |
| | | name: 'EamReportRepairList', |
| | | mixins: [JeecgListMixin], |
| | | components: { |
| | | ImagesPreviewModal, |
| | | LxSearchEquipmentSelect, |
| | | EamReportRepairModal |
| | | }, |
| | | data() { |
| | | return { |
| | | description: 'æ
éæ¥ä¿®ç®¡ç页é¢', |
| | | // 表头 |
| | | columns: [ |
| | | { |
| | | title: '#', |
| | | dataIndex: '', |
| | | key: 'rowIndex', |
| | | width: 60, |
| | | align: 'center', |
| | | customRender: function(t, r, index) { |
| | | return parseInt(index) + 1 |
| | | export default { |
| | | name: 'EamReportRepairList', |
| | | mixins: [JeecgListMixin], |
| | | components: { |
| | | ImagesPreviewModal, |
| | | LxSearchEquipmentSelect, |
| | | EamReportRepairModal |
| | | }, |
| | | props: { |
| | | isDisplayOperation: { |
| | | type: Boolean, |
| | | default: true |
| | | }, |
| | | propsQueryParam: { |
| | | type: Object |
| | | } |
| | | }, |
| | | data() { |
| | | return { |
| | | description: 'æ
éæ¥ä¿®ç®¡ç页é¢', |
| | | disableMixinCreated: true, |
| | | // 表头 |
| | | columns: [ |
| | | { |
| | | title: '#', |
| | | dataIndex: '', |
| | | key: 'rowIndex', |
| | | width: 60, |
| | | align: 'center', |
| | | customRender: function(t, r, index) { |
| | | return parseInt(index) + 1 |
| | | } |
| | | }, |
| | | { |
| | | title: '设å¤ç¼å·', |
| | | align: 'center', |
| | | dataIndex: 'equipmentId_dictText', |
| | | width: 200 |
| | | }, |
| | | { |
| | | title: 'ç¶æ', |
| | | align: 'center', |
| | | dataIndex: 'reportStatus_dictText', |
| | | width: 100 |
| | | }, |
| | | { |
| | | title: 'æ
éç®ç§°', |
| | | align: 'center', |
| | | dataIndex: 'faultName', |
| | | width: 100 |
| | | }, |
| | | { |
| | | title: 'æ
éåç±»', |
| | | align: 'center', |
| | | dataIndex: 'faultType_dictText', |
| | | width: 100 |
| | | }, |
| | | { |
| | | title: 'æ
éæè¿°', |
| | | align: 'center', |
| | | dataIndex: 'faultDescription', |
| | | width: 200 |
| | | }, |
| | | { |
| | | title: 'æ
éå¼å§æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'faultStartTime', |
| | | width: 200 |
| | | }, |
| | | { |
| | | title: 'æ¯å¦åæº', |
| | | align: 'center', |
| | | dataIndex: 'breakdownFlag_dictText', |
| | | width: 100 |
| | | }, |
| | | { |
| | | title: 'æ¥ä¿®å¾ç', |
| | | align: 'center', |
| | | dataIndex: 'imageFiles', |
| | | scopedSlots: { customRender: 'imageFiles' }, |
| | | width: 100 |
| | | }, |
| | | { |
| | | title: '夿³¨', |
| | | align: 'center', |
| | | dataIndex: 'remark' |
| | | } |
| | | }, |
| | | { |
| | | title: '设å¤ç¼å·', |
| | | align: 'center', |
| | | dataIndex: 'equipmentId_dictText', |
| | | width: 200 |
| | | }, |
| | | { |
| | | title: 'ç¶æ', |
| | | align: 'center', |
| | | dataIndex: 'reportStatus_dictText', |
| | | width: 100 |
| | | }, |
| | | { |
| | | title: 'æ
éç®ç§°', |
| | | align: 'center', |
| | | dataIndex: 'faultName', |
| | | width: 100 |
| | | }, |
| | | { |
| | | title: 'æ
éåç±»', |
| | | align: 'center', |
| | | dataIndex: 'faultType_dictText', |
| | | width: 100 |
| | | }, |
| | | { |
| | | title: 'æ
éæè¿°', |
| | | align: 'center', |
| | | dataIndex: 'faultDescription', |
| | | width: 200 |
| | | }, |
| | | { |
| | | title: 'æ
éå¼å§æ¶é´', |
| | | align: 'center', |
| | | dataIndex: 'faultStartTime', |
| | | width: 200 |
| | | }, |
| | | { |
| | | title: 'æ¯å¦åæº', |
| | | align: 'center', |
| | | dataIndex: 'breakdownFlag_dictText', |
| | | width: 100 |
| | | }, |
| | | { |
| | | title: 'æ¥ä¿®å¾ç', |
| | | align: 'center', |
| | | dataIndex: 'imageFiles', |
| | | scopedSlots: { customRender: 'imageFiles' }, |
| | | width: 100 |
| | | }, |
| | | { |
| | | title: '夿³¨', |
| | | align: 'center', |
| | | dataIndex: 'remark' |
| | | }, |
| | | { |
| | | ], |
| | | breakdown_flag_list: [], |
| | | report_repair_status_list: [], |
| | | faultTimeRange: [], |
| | | faultReasonList: [], |
| | | currentImageListUrl: '', |
| | | url: { |
| | | list: '/eam/eamReportRepair/list', |
| | | delete: '/eam/eamReportRepair/abolish', |
| | | deleteBatch: '/eam/eamReportRepair/abolishBatch', |
| | | exportXlsUrl: 'eam/eamReportRepair/exportXls', |
| | | importExcelUrl: 'eam/eamReportRepair/importExcel', |
| | | faultReasonList: '/eam/equipmentFaultReason/list' |
| | | } |
| | | } |
| | | }, |
| | | computed: { |
| | | importExcelUrl: function() { |
| | | return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}` |
| | | } |
| | | }, |
| | | created() { |
| | | this.initDictData('breakdown_flag') |
| | | this.initDictData('report_repair_status') |
| | | this.getFaultReasonListByApi() |
| | | if (!this.isDisplayOperation) this.queryParam = Object.assign({} ,this.propsQueryParam) |
| | | else { |
| | | const operationColumn = { |
| | | title: 'æä½', |
| | | dataIndex: 'action', |
| | | align: 'center', |
| | | scopedSlots: { customRender: 'action' }, |
| | | width: 150 |
| | | } |
| | | ], |
| | | breakdown_flag_list: [], |
| | | report_repair_status_list: [], |
| | | faultTimeRange: [], |
| | | faultReasonList: [], |
| | | currentImageListUrl: '', |
| | | url: { |
| | | list: '/eam/eamReportRepair/list', |
| | | delete: '/eam/eamReportRepair/abolish', |
| | | deleteBatch: '/eam/eamReportRepair/abolishBatch', |
| | | exportXlsUrl: 'eam/eamReportRepair/exportXls', |
| | | importExcelUrl: 'eam/eamReportRepair/importExcel', |
| | | faultReasonList: '/eam/equipmentFaultReason/list' |
| | | this.columns = [...this.columns, operationColumn] |
| | | } |
| | | } |
| | | }, |
| | | computed: { |
| | | importExcelUrl: function() { |
| | | return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}` |
| | | } |
| | | }, |
| | | created() { |
| | | this.initDictData('breakdown_flag') |
| | | this.initDictData('report_repair_status') |
| | | this.getFaultReasonListByApi() |
| | | }, |
| | | methods: { |
| | | /** |
| | | * è·åæ°æ®åå
¸å¼ |
| | | * @param dictCode æ°æ®åå
¸å¯¹åºè®°å½ç¼ç |
| | | */ |
| | | initDictData(dictCode) { |
| | | // //ä¼å
ä»ç¼åä¸è¯»ååå
¸é
ç½® |
| | | if (getDictItemsFromCache(dictCode)) { |
| | | this[dictCode + '_list'] = getDictItemsFromCache(dictCode) |
| | | return |
| | | } |
| | | //æ ¹æ®åå
¸Code, åå§ååå
¸æ°ç» |
| | | ajaxGetDictItems(dictCode, null).then((res) => { |
| | | if (res.success) { |
| | | this[dictCode + '_list'] = res.result |
| | | this.loadData(1) |
| | | }, |
| | | methods: { |
| | | /** |
| | | * è·åæ°æ®åå
¸å¼ |
| | | * @param dictCode æ°æ®åå
¸å¯¹åºè®°å½ç¼ç |
| | | */ |
| | | initDictData(dictCode) { |
| | | // //ä¼å
ä»ç¼åä¸è¯»ååå
¸é
ç½® |
| | | if (getDictItemsFromCache(dictCode)) { |
| | | this[dictCode + '_list'] = getDictItemsFromCache(dictCode) |
| | | return |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | // è°ç¨æ¥å£è·åæ
éåå å表 |
| | | getFaultReasonListByApi() { |
| | | const that = this |
| | | getAction(this.url.faultReasonList) |
| | | .then(res => { |
| | | console.log('res', res) |
| | | that.faultReasonList = res.result.records |
| | | //æ ¹æ®åå
¸Code, åå§ååå
¸æ°ç» |
| | | ajaxGetDictItems(dictCode, null).then((res) => { |
| | | if (res.success) { |
| | | this[dictCode + '_list'] = res.result |
| | | return |
| | | } |
| | | }) |
| | | }, |
| | | }, |
| | | |
| | | /** |
| | | * æ
éæ¶é´éæ©å¨ååæ¶è§¦å |
| | | * @param valueArray |
| | | */ |
| | | handleTimeRangeChange(valueArray) { |
| | | this.queryParam.startTime = valueArray[0] |
| | | this.queryParam.endTime = valueArray[1] |
| | | }, |
| | | // è°ç¨æ¥å£è·åæ
éåå å表 |
| | | getFaultReasonListByApi() { |
| | | const that = this |
| | | getAction(this.url.faultReasonList) |
| | | .then(res => { |
| | | console.log('res', res) |
| | | that.faultReasonList = res.result.records |
| | | }) |
| | | }, |
| | | |
| | | /** |
| | | * é¢è§å¾ç |
| | | * @param imageFiles è¡¨æ ¼è¡å¾çå°å |
| | | */ |
| | | handlePreviewImages({ imageFiles }) { |
| | | this.currentImageListUrl = imageFiles |
| | | this.$refs.imagesPreviewModalRef.visible = true |
| | | }, |
| | | /** |
| | | * æ
éæ¶é´éæ©å¨ååæ¶è§¦å |
| | | * @param valueArray |
| | | */ |
| | | handleTimeRangeChange(valueArray) { |
| | | this.queryParam.startTime = valueArray[0] |
| | | this.queryParam.endTime = valueArray[1] |
| | | }, |
| | | |
| | | searchReset() { |
| | | this.queryParam = {} |
| | | this.faultTimeRange = [] |
| | | this.loadData(1) |
| | | /** |
| | | * é¢è§å¾ç |
| | | * @param imageFiles è¡¨æ ¼è¡å¾çå°å |
| | | */ |
| | | handlePreviewImages({ imageFiles }) { |
| | | this.currentImageListUrl = imageFiles |
| | | this.$refs.imagesPreviewModalRef.visible = true |
| | | }, |
| | | |
| | | searchReset() { |
| | | if (this.isDisplayOperation) this.queryParam = {} |
| | | else this.queryParam = Object.assign({}, this.propsQueryParam) |
| | | this.faultTimeRange = [] |
| | | this.loadData(1) |
| | | } |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | <style scoped> |
| | | @import '~@assets/less/common.less'; |
| | | @import '~@assets/less/common.less'; |
| | | </style> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <j-modal |
| | | :title="title" |
| | | width="80%" |
| | | :visible="visible" |
| | | :confirmLoading="confirmLoading" |
| | | switchFullscreen |
| | | @ok="handleOk" |
| | | @cancel="handleCancel" |
| | | centered |
| | | cancelText="å
³é"> |
| | | <eam-report-repair-list ref="reportRepairListRef" :isDisplayOperation="false" |
| | | :propsQueryParam="{reportStatus:'WAIT_REPAIR'}"/> |
| | | </j-modal> |
| | | </template> |
| | | |
| | | <script> |
| | | import { httpAction } from '@api/manage' |
| | | import EamReportRepairList from '../../EamReportRepairList' |
| | | |
| | | export default { |
| | | name: 'ReceiveFaultModal', |
| | | components: { EamReportRepairList }, |
| | | data() { |
| | | return { |
| | | title: 'æ
éä¿ä¿®å', |
| | | visible: false, |
| | | model: {}, |
| | | labelCol: { |
| | | xs: { span: 24 }, |
| | | sm: { span: 8 } |
| | | }, |
| | | wrapperCol: { |
| | | xs: { span: 24 }, |
| | | sm: { span: 12 } |
| | | }, |
| | | labelColLong: { |
| | | xs: { span: 24 }, |
| | | sm: { span: 4 } |
| | | }, |
| | | wrapperColLong: { |
| | | xs: { span: 24 }, |
| | | sm: { span: 18 } |
| | | }, |
| | | confirmLoading: false, |
| | | validatorRules: {}, |
| | | url: { |
| | | receiveFault: '/eam/eamRepairOrder/add' |
| | | } |
| | | } |
| | | }, |
| | | created() { |
| | | }, |
| | | methods: { |
| | | loadData() { |
| | | this.$nextTick(() => { |
| | | // this.$refs.reportRepairListRef.queryParam.reportStatus = 'WAIT_REPAIR' |
| | | // this.$refs.reportRepairListRef.loadData(1) |
| | | }) |
| | | }, |
| | | close() { |
| | | this.$emit('close') |
| | | this.visible = false |
| | | }, |
| | | handleOk() { |
| | | console.log('rowKey', this.$refs.reportRepairListRef.selectedRowKeys[0]) |
| | | const reportId = this.$refs.reportRepairListRef.selectedRowKeys[0] |
| | | this.confirmLoading = true |
| | | httpAction(this.url.receiveFault, { reportId }, 'post').then((res) => { |
| | | if (res.success) { |
| | | this.$message.success(res.message) |
| | | this.$emit('ok') |
| | | } else { |
| | | this.$message.warning(res.message) |
| | | } |
| | | }).finally(() => { |
| | | this.confirmLoading = false |
| | | this.close() |
| | | }) |
| | | }, |
| | | handleCancel() { |
| | | this.close() |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style lang="less" scoped> |
| | | |
| | | </style> |