¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <div style="width: 100%; height: 100%;"> |
| | | <a-card :bordered="false"> |
| | | <a-row type="flex" :gutter="16"> |
| | | <a-col :md="5"> |
| | | <a-tabs :activeKey="activeKey" @change="tabChange"> |
| | | <a-tab-pane key="1" tab="车é´å±çº§" force-render> |
| | | <base-tree @getCurrSelected="changeSelectionNode"></base-tree> |
| | | </a-tab-pane> |
| | | <a-tab-pane v-if="isDepartType == 0" key="2" tab="é¨é¨å±çº§">, |
| | | <depart-tree @getCurrSelectedDD="changeSelectionNodedd"></depart-tree> |
| | | </a-tab-pane> |
| | | </a-tabs> |
| | | </a-col> |
| | | <a-col :md="19"> |
| | | <OEEAnalysisList :nodePeople='selectPeople' :nodeTree='selectEquipment' :Type="selectTypeTree"/> |
| | | </a-col> |
| | | </a-row> |
| | | </a-card> |
| | | </div> |
| | | |
| | | </template> |
| | | |
| | | <script> |
| | | import { JeecgListMixin } from '@/mixins/JeecgListMixin' |
| | | import BaseTree from '../common/BaseTree' |
| | | import OEEAnalysisList from './modules/OEEAnalysis/OEEAnalysisList' |
| | | import DepartTree from './modules/DepartList/DepartListTree/DepartTree' |
| | | import { mapActions } from 'vuex' |
| | | |
| | | export default { |
| | | name: 'OEEAnalysis', |
| | | components: { |
| | | BaseTree, |
| | | DepartTree, |
| | | OEEAnalysisList |
| | | }, |
| | | data() { |
| | | return { |
| | | activeKey: '1', |
| | | selectEquipmentId: '', |
| | | selectEquipment: {}, |
| | | selectPeople: {}, |
| | | selectTypeTree: '', |
| | | isDepartType: '' |
| | | } |
| | | }, |
| | | created() { |
| | | this.queryTreeData() |
| | | }, |
| | | methods: { |
| | | ...mapActions(['QueryDepartTree']), |
| | | queryTreeData() { |
| | | this.QueryDepartTree().then(res => { |
| | | if (res.success) { |
| | | this.isDepartType = res.result[0].value |
| | | } else { |
| | | // this.$message.warn(res.message) |
| | | this.$notification.warning({ |
| | | message: 'æ¶æ¯', |
| | | description: res.message |
| | | }) |
| | | } |
| | | }).finally(() => { |
| | | }) |
| | | }, |
| | | tabChange(val) { |
| | | this.activeKey = val |
| | | this.selectTypeTree = val |
| | | }, |
| | | changeSelectionNode(val) { |
| | | this.selectEquipment = val |
| | | this.selectTypeTree = '1' |
| | | }, |
| | | changeSelectionNodedd(val) { |
| | | this.selectPeople = val |
| | | this.selectTypeTree = '2' |
| | | } |
| | | } |
| | | |
| | | } |
| | | </script> |
| | |
| | | <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" allowClear/> |
| | | <a-input placeholder="请è¾å
¥è®¾å¤ç¼å·" v-model="queryParam.equipmentId"/> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> |
| | | <a-space> |
| | | <a-button type="primary" @click="searchQuery" icon="search">æ¥è¯¢</a-button> |
| | | <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">éç½®</a-button> |
| | | </span> |
| | | <a-button type="primary" @click="searchReset" icon="reload">éç½®</a-button> |
| | | </a-space> |
| | | </a-col> |
| | | </a-row> |
| | | </a-form> |
| | |
| | | <!-- æä½æé®åºå --> |
| | | <div class="table-operator"> |
| | | <a-button @click="handleAdd" type="primary" icon="plus">æ°å¢</a-button> |
| | | <a-button type="primary" icon="download" @click="importTemplate('计ååæºæ¨¡æ¿')">导å
¥æ¨¡æ¿</a-button> |
| | | <a-button type="primary" icon="download" @click="importTemplate('计ååæºç®¡ç')">导å
¥æ¨¡æ¿</a-button> |
| | | <a-button type="primary" icon="download" @click="handleExportXls('计ååæºç®¡ç')">导åº</a-button> |
| | | <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" |
| | | @change="handleImportExcel"> |
| | |
| | | <!-- tableåºå-begin --> |
| | | <div id="DeviceList" style="flex: 1;overflow: hidden"> |
| | | <a-table |
| | | id="planClose" |
| | | ref="table" |
| | | size="middle" |
| | | :scroll="{x:'max-content',y:scrollY}" |
| | |
| | | exportXlsUrl: '/mdc/mdcPlanClose/exportXls', |
| | | importExcelUrl: 'mdc/mdcPlanClose/importExcel' |
| | | }, |
| | | dictOptions: {}, |
| | | superFieldList: [] |
| | | } |
| | | }, |
| | | watch: { |
| | |
| | | }, |
| | | importTemplate(fileName) { |
| | | var a = document.createElement('a') |
| | | a.href = '/static/计ååæºç®¡ç.xls' |
| | | a.download = '计ååæºç®¡ç.xls' |
| | | a.href = `/static/${fileName}.xls` |
| | | a.download = `${fileName}.xls` |
| | | a.style.display = 'none' |
| | | document.body.appendChild(a) |
| | | a.click() |
| | |
| | | <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" allowClear/> |
| | | <a-input placeholder="请è¾å
¥è®¾å¤ç¼å·" v-model="queryParam.equipmentId"/> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> |
| | | <a-space> |
| | | <a-button type="primary" @click="searchQuery" icon="search">æ¥è¯¢</a-button> |
| | | <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">éç½®</a-button> |
| | | </span> |
| | | <a-button type="primary" @click="searchReset" icon="reload">éç½®</a-button> |
| | | </a-space> |
| | | </a-col> |
| | | </a-row> |
| | | </a-form> |
| | |
| | | <!-- æä½æé®åºå --> |
| | | <div class="table-operator"> |
| | | <a-button @click="handleAdd" type="primary" icon="plus">æ°å¢</a-button> |
| | | <a-button type="primary" icon="download" @click="importTemplate('é计ååæºæ¨¡æ¿')">导å
¥æ¨¡æ¿</a-button> |
| | | <a-button type="primary" icon="download" @click="importTemplate('é计ååæºç®¡ç')">导å
¥æ¨¡æ¿</a-button> |
| | | <a-button type="primary" icon="download" @click="handleExportXls('é计ååæºç®¡ç')">导åº</a-button> |
| | | <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" |
| | | @change="handleImportExcel"> |
| | |
| | | <!-- tableåºå-begin --> |
| | | <div id="DeviceList" style="flex: 1;overflow: hidden"> |
| | | <a-table |
| | | id="planClose" |
| | | ref="table" |
| | | size="middle" |
| | | :scroll="{x:'max-content',y:scrollY}" |
| | |
| | | exportXlsUrl: '/mdc/mdcPlanClose/exportXls', |
| | | importExcelUrl: 'mdc/mdcPlanClose/importExcel' |
| | | }, |
| | | dictOptions: {}, |
| | | superFieldList: [] |
| | | } |
| | | }, |
| | | watch: { |
| | |
| | | }, |
| | | importTemplate(fileName) { |
| | | var a = document.createElement('a') |
| | | a.href = '/static/é计ååæºç®¡ç.xls' |
| | | a.download = 'é计ååæºç®¡ç.xls' |
| | | a.href = `/static/${fileName}.xls` |
| | | a.download = `${fileName}.xls` |
| | | a.style.display = 'none' |
| | | document.body.appendChild(a) |
| | | a.click() |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <div class="device_list"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | | <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-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <a-form-item label="æ¥æ"> |
| | | <a-range-picker v-model="dates" style="width: 100%" @change="dateParamChange"></a-range-picker> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <a-space> |
| | | <a-button type="primary" @click="searchQuery" icon="search">æ¥è¯¢</a-button> |
| | | <a-button type="primary" @click="searchReset" icon="reload">éç½®</a-button> |
| | | </a-space> |
| | | </a-col> |
| | | </a-row> |
| | | </a-form> |
| | | </div> |
| | | <!-- æ¥è¯¢åºå-END --> |
| | | |
| | | <!-- æä½æé®åºå --> |
| | | <div class="table-operator"> |
| | | <a-button type="primary" icon="download" @click="handleExportXls('OEE')">导åº</a-button> |
| | | </div> |
| | | |
| | | <!-- tableåºå-begin --> |
| | | <div id="DeviceList" style="flex: 1;overflow: hidden"> |
| | | <a-table |
| | | ref="table" |
| | | size="middle" |
| | | :scroll="{x:'max-content',y:scrollY}" |
| | | bordered |
| | | rowKey="id" |
| | | :columns="columns" |
| | | :dataSource="dataSource" |
| | | :pagination="ipagination" |
| | | :loading="loading"> |
| | | <template slot="percent" slot-scope="text"> |
| | | {{text+'%'}} |
| | | </template> |
| | | </a-table> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import moment from 'moment' |
| | | import { JeecgListMixin } from '@/mixins/JeecgListMixin' |
| | | |
| | | export default { |
| | | name: 'OEEAnalysisList', |
| | | mixins: [JeecgListMixin], |
| | | components: {}, |
| | | props: { nodeTree: '', Type: '', nodePeople: '' }, |
| | | data() { |
| | | return { |
| | | description: 'OEE页é¢', |
| | | disableMixinCreated: true, |
| | | /* å页忰 */ |
| | | ipagination: { |
| | | current: 1, |
| | | pageSize: 30, |
| | | pageSizeOptions: ['30', '50', '100'], |
| | | showTotal: (total, range) => { |
| | | return range[0] + '-' + range[1] + ' å
±' + total + 'æ¡' |
| | | }, |
| | | showQuickJumper: true, |
| | | showSizeChanger: true, |
| | | total: 0 |
| | | }, |
| | | dates: [moment().subtract(1, 'day'), moment()], |
| | | queryParam: {}, |
| | | // 表头 |
| | | columns: [ |
| | | { |
| | | title: '#', |
| | | dataIndex: '', |
| | | key: 'rowIndex', |
| | | width: 60, |
| | | align: 'center', |
| | | customRender: function(t, r, index) { |
| | | return parseInt(index) + 1 |
| | | } |
| | | }, |
| | | { |
| | | title: '设å¤ç¼å·', |
| | | align: 'center', |
| | | dataIndex: 'equipmentId', |
| | | width: 230 |
| | | }, |
| | | { |
| | | title: 'æ¥æ', |
| | | align: 'center', |
| | | dataIndex: 'theDate', |
| | | width: 150 |
| | | }, |
| | | { |
| | | title: 'æ¥å工使¶é´(min)', |
| | | align: 'center', |
| | | dataIndex: 'calendarLong', |
| | | width: 150 |
| | | }, |
| | | { |
| | | title: '计ååæºæ¶é´(min)', |
| | | align: 'center', |
| | | dataIndex: 'planCloseLong', |
| | | width: 150 |
| | | }, |
| | | { |
| | | title: 'è´è·æ¶é´(min)', |
| | | align: 'center', |
| | | dataIndex: 'loadLong', |
| | | width: 150 |
| | | }, |
| | | { |
| | | title: 'é计ååæºæ¶é´(min)', |
| | | align: 'center', |
| | | dataIndex: 'noplanCloseLong', |
| | | width: 150 |
| | | }, |
| | | { |
| | | title: 'å¼å¨æ¶é´(min)', |
| | | align: 'center', |
| | | dataIndex: 'actuateLong', |
| | | width: 150 |
| | | }, |
| | | { |
| | | title: 'æ¶é´å¼å¨ç', |
| | | align: 'center', |
| | | dataIndex: 'timeActuationRate', |
| | | width: 150, |
| | | scopedSlots: { customRender: 'percent' } |
| | | }, |
| | | { |
| | | title: 'ææè¿è¡æ¶é´(min)', |
| | | align: 'center', |
| | | dataIndex: 'effectiveRunLong', |
| | | width: 150 |
| | | }, |
| | | { |
| | | title: 'æ§è½å¼å¨ç', |
| | | align: 'center', |
| | | dataIndex: 'performanceRate', |
| | | width: 150, |
| | | scopedSlots: { customRender: 'percent' } |
| | | }, |
| | | { |
| | | title: 'å å·¥é¶ä»¶æ°é', |
| | | align: 'center', |
| | | dataIndex: 'processCount', |
| | | width: 150 |
| | | }, |
| | | { |
| | | title: 'åæ ¼é¶ä»¶æ°é', |
| | | align: 'center', |
| | | dataIndex: 'passCount', |
| | | width: 150 |
| | | }, |
| | | { |
| | | title: '䏿¬¡åæ ¼ç', |
| | | align: 'center', |
| | | dataIndex: 'passRate', |
| | | width: 150, |
| | | scopedSlots: { customRender: 'percent' } |
| | | }, |
| | | { |
| | | title: 'OEE', |
| | | align: 'center', |
| | | dataIndex: 'oee', |
| | | width: 150, |
| | | scopedSlots: { customRender: 'percent' } |
| | | } |
| | | ], |
| | | scrollY: 465, |
| | | url: { |
| | | list: '/mdc/mdcOeeInfo/list', |
| | | exportXlsUrl: '/mdc/mdcOeeInfo/exportXls' |
| | | } |
| | | } |
| | | }, |
| | | watch: { |
| | | Type(valmath) { |
| | | this.dataList = [] |
| | | this.queryParam.typeTree = valmath |
| | | // console.log(this.queryParam.typeTree) |
| | | }, |
| | | nodeTree(val) { //çå¬currSelected ååï¼å°åååçæ°å¼ä¼ éç» getCurrSelected äºä»¶ |
| | | if (JSON.stringify(val) != '{}') { |
| | | if (val.equipmentId) { |
| | | this.queryParam.parentId = '' |
| | | this.queryParam.equipmentId = val.equipmentId |
| | | } else { |
| | | this.queryParam.parentId = val.key |
| | | this.queryParam.equipmentId = '' |
| | | } |
| | | this.searchQuery() |
| | | } |
| | | }, |
| | | nodePeople(val) { |
| | | if (JSON.stringify(val) != '{}') { |
| | | if (val.equipmentId) { |
| | | this.queryParam.parentId = '' |
| | | this.queryParam.equipmentId = val.equipmentId |
| | | } else { |
| | | this.queryParam.parentId = val.key |
| | | this.queryParam.equipmentId = '' |
| | | } |
| | | this.searchQuery() |
| | | } |
| | | } |
| | | }, |
| | | methods: { |
| | | dateParamChange(v1, v2) { |
| | | this.queryParam.startTime = v2[0] |
| | | this.queryParam.endTime = v2[1] |
| | | this.dates = [v1[0], v1[1]] |
| | | }, |
| | | searchReset() { |
| | | this.dates = [moment().subtract(1, 'day'), moment()] |
| | | this.queryParam = { |
| | | startTime: this.dates[0].format('YYYY-MM-DD'), |
| | | endTime: this.dates[1].format('YYYY-MM-DD') |
| | | } |
| | | this.loadData(1) |
| | | }, |
| | | /** |
| | | * 彿µè§å¨å¯è§çªå£å°ºå¯¸åçæ¹åæ¶è§¦å |
| | | */ |
| | | handleWindowResize() { |
| | | const boxHeight = +window.getComputedStyle(document.getElementById('DeviceList')).height.slice(0, -2) |
| | | const tableHeadHeight = +window.getComputedStyle(document.querySelector('.ant-table-thead th')).height.slice(0, -2) |
| | | this.scrollY = boxHeight - tableHeadHeight - 50 |
| | | } |
| | | }, |
| | | created() { |
| | | this.queryParam.startTime = this.dates[0].format('YYYY-MM-DD') |
| | | this.queryParam.endTime = this.dates[1].format('YYYY-MM-DD') |
| | | this.loadData() |
| | | }, |
| | | mounted() { |
| | | window.addEventListener('resize', this.handleWindowResize) |
| | | this.handleWindowResize() |
| | | }, |
| | | beforeDestroy() { |
| | | window.removeEventListener('resize', this.handleWindowResize) |
| | | } |
| | | } |
| | | </script> |
| | | <style scoped> |
| | | @import '~@assets/less/common.less'; |
| | | |
| | | .device_list { |
| | | display: flex; |
| | | flex-direction: column; |
| | | overflow: hidden; |
| | | } |
| | | |
| | | @media screen and (min-width: 1920px) { |
| | | .device_list { |
| | | height: 811px !important; |
| | | } |
| | | } |
| | | |
| | | @media screen and (min-width: 1680px) and (max-width: 1920px) { |
| | | .device_list { |
| | | height: 811px !important; |
| | | } |
| | | } |
| | | |
| | | @media screen and (min-width: 1400px) and (max-width: 1680px) { |
| | | .device_list { |
| | | height: 663px !important; |
| | | } |
| | | } |
| | | |
| | | @media screen and (min-width: 1280px) and (max-width: 1400px) { |
| | | .device_list { |
| | | height: 564px !important; |
| | | } |
| | | } |
| | | |
| | | @media screen and (max-width: 1280px) { |
| | | .device_list { |
| | | height: 564px !important; |
| | | } |
| | | } |
| | | </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" allowClear/> |
| | | <a-input placeholder="请è¾å
¥è®¾å¤ç¼å·" v-model="queryParam.equipmentId"/> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> |
| | | <a-space> |
| | | <a-button type="primary" @click="searchQuery" icon="search">æ¥è¯¢</a-button> |
| | | <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">éç½®</a-button> |
| | | </span> |
| | | <a-button type="primary" @click="searchReset" icon="reload">éç½®</a-button> |
| | | </a-space> |
| | | </a-col> |
| | | </a-row> |
| | | </a-form> |
| | |
| | | <!-- tableåºå-begin --> |
| | | <div id="DeviceList" style="flex: 1;overflow: hidden"> |
| | | <a-table |
| | | id="planClose" |
| | | ref="table" |
| | | size="middle" |
| | | :scroll="{x:'max-content',y:scrollY}" |
| | |
| | | deleteBatch: '/mdc/mdcPartProcessInfo/deleteBatch', |
| | | exportXlsUrl: '/mdc/mdcPartProcessInfo/exportXls', |
| | | importExcelUrl: '/mdc/mdcPartProcessInfo/importExcel' |
| | | }, |
| | | } |
| | | } |
| | | }, |
| | | watch: { |