1、优化车间看板四色灯状态展示以及限制拖拽区域
2、部分页面右侧区域元素位置离顶过高,调整布局
3、增加设备日志页面增加点击表格行数据展示当前行工作曲线功能
4、优化设备日志页面切换时间,工作曲线弹窗中的时间随之切换
5、优化设备日志页面加载后首次点击工作曲线后无法查询到数据问题(同时发送异步请求,先后顺序影响)
| | |
| | | meta: { title: 'é¦é¡µ' }, |
| | | redirect: '/dashboard/analysis', |
| | | children: [ |
| | | |
| | | // // dashboard |
| | | // { |
| | | // path: '/dashboard', |
| | |
| | | ] |
| | | }, |
| | | { |
| | | path:'/testWorkshop', |
| | | component:()=>import('@/views/TestWorkshop.vue') |
| | | path:'/workshopSignage/:workshopId', |
| | | component:()=>import('@/views/WorkshopSignage.vue') |
| | | }, |
| | | { |
| | | path: '/404', |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <dv-full-screen-container class="full-screen-container"> |
| | | <header class="page-header"> |
| | | {{getWorkshopName}} |
| | | <div class="header-right"> |
| | | <a-button type="primary" icon="save" size="large" @click="saveDevicePositionByApi">ä¿åä½ç½®</a-button> |
| | | </div> |
| | | </header> |
| | | |
| | | <dv-border-box-8 class="content-container"> |
| | | <div v-for="item in deviceList" :key="item.equipmentId" class="single-device" |
| | | :style="{top:item.top+'px',left:item.left+'px',height:'135px',width:'175px'}" @mousedown="handleMouseDown" |
| | | :id="item.equipmentId"> |
| | | <div class="device-status"> |
| | | <img v-if="item.status==0" src="@/assets/yellow.png" draggable="false"> |
| | | <img v-if="item.status==1" src="@/assets/red.png" draggable="false"> |
| | | <img v-if="item.status==2" src="@/assets/gray.png" draggable="false"> |
| | | <img v-if="item.status==3" src="@/assets/green.png" draggable="false"> |
| | | <img :src="item.equipmentImageUrl" draggable="false"> |
| | | </div> |
| | | <div class="device-id">{{item.equipmentId}}</div> |
| | | <!--<div draggable="false" class="device-info">--> |
| | | <!--<div v-if="item.status==0" class="status-square" style="background-color: gray"></div>--> |
| | | <!--<div v-if="item.status==1" class="status-square" style="background-color: red"></div>--> |
| | | <!--<div v-if="item.status==2" class="status-square" style="background-color: green"></div>--> |
| | | <!--<div v-if="item.status==3" class="status-square" style="background-color: yellow"></div>--> |
| | | <!--<div class="device-id">{{item.equipmentId}}</div>--> |
| | | <!--</div>--> |
| | | </div> |
| | | <!--<div style="width: 175px;height: 135px;background-color: red;position: absolute;top: 200px;left: 100px"></div>--> |
| | | </dv-border-box-8> |
| | | </dv-full-screen-container> |
| | | </template> |
| | | |
| | | <script> |
| | | export default { |
| | | data() { |
| | | return { |
| | | mouseX: 0, // é¼ æ å¨å
ç´ å
çXåæ |
| | | mouseY: 0, // é¼ æ å¨å
ç´ å
çYåæ , |
| | | dragging: false, //æ¯å¦å¨ææ½ä¸ |
| | | left: 0, // å
ç´ å·¦ä¸è§è·ç¦»ç¶å®¹å¨å·¦ä¾§çè·ç¦» |
| | | top: 0, // å
ç´ å·¦ä¸è§è·ç¦»ç¶å®¹å¨é¡¶é¨çè·ç¦», |
| | | elementId: '',// è¢«ææ½å
ç´ çid屿§å¼ |
| | | elementWidth: '', |
| | | elementHeight: '', |
| | | deviceList: [ |
| | | { |
| | | equipmentId: '123213213123232', |
| | | equipmentImageUrl: require('@/assets/8.png'), |
| | | top: 200, |
| | | left: 100, |
| | | status: 1 |
| | | }, |
| | | { |
| | | equipmentId: '512346789561232', |
| | | equipmentImageUrl: require('@/assets/8.png'), |
| | | top: 500, |
| | | left: 753, |
| | | status: 0 |
| | | }, |
| | | { |
| | | equipmentId: '64746965647653', |
| | | equipmentImageUrl: require('@/assets/8.png'), |
| | | top: 300, |
| | | left: 860, |
| | | status: 2 |
| | | }, |
| | | { |
| | | equipmentId: '33548976965462', |
| | | equipmentImageUrl: require('@/assets/8.png'), |
| | | top: 100, |
| | | left: 380, |
| | | status: 3 |
| | | }, |
| | | { |
| | | equipmentId: '85484913549253', |
| | | equipmentImageUrl: require('@/assets/8.png'), |
| | | top: 200, |
| | | left: 1500, |
| | | status: 2 |
| | | } |
| | | ] |
| | | } |
| | | }, |
| | | computed: { |
| | | getWorkshopName() { |
| | | switch (this.$route.params.workshopId) { |
| | | case '5321': |
| | | return 'é¿æ²è½¦é´' |
| | | case '6312': |
| | | return '天津车é´' |
| | | case '3463': |
| | | return 'æ¦æ±è½¦é´' |
| | | case '8421': |
| | | return 'å京车é´' |
| | | default: |
| | | return 'æµè¯è½¦é´' |
| | | } |
| | | } |
| | | }, |
| | | methods: { |
| | | /** |
| | | * éè¿è½¦é´Idè°ç¨æ¥å£è·å设å¤å表 |
| | | * @param workshopId 车é´Id |
| | | */ |
| | | getDeviceListByApi(workshopId) { |
| | | console.log('车é´Id', workshopId) |
| | | }, |
| | | /** |
| | | * ææ½å¯¹è±¡é¼ æ æé®æä¸äºä»¶ |
| | | * @param event |
| | | */ |
| | | handleMouseDown(event) { |
| | | this.dragging = true |
| | | this.mouseX = event.clientX |
| | | this.mouseY = event.clientY |
| | | this.elementId = event.currentTarget.id |
| | | this.top = event.currentTarget.offsetTop |
| | | this.left = event.currentTarget.offsetLeft |
| | | document.addEventListener('mousemove', this.handleMouseMove) |
| | | document.addEventListener('mouseup', this.handleMouseUp) |
| | | this.elementWidth = +event.currentTarget.style.width.replace('px', '') |
| | | this.elementHeight = +event.currentTarget.style.height.replace('px', '') |
| | | }, |
| | | /** |
| | | * ææ¡£å¯¹è±¡é¼ æ ç§»å¨äºä»¶ |
| | | * @param event |
| | | */ |
| | | handleMouseMove(event) { |
| | | if (this.dragging) { |
| | | // xæ¹åé¼ æ åç§»é |
| | | const deltaX = event.clientX - this.mouseX |
| | | // yæ¹åé¼ æ åç§»é |
| | | const deltaY = event.clientY - this.mouseY |
| | | this.left += deltaX |
| | | this.top += deltaY |
| | | this.deviceList.forEach(item => { |
| | | if (item.equipmentId === this.elementId) { |
| | | item.top = this.top |
| | | item.left = this.left |
| | | // éå¶ææ½è¶
åºåºå(ç¼©æ¾æµè§å¨çªå£åè·åå¨è·ç¦»åºç°é®é¢) |
| | | if (item.top < 0) { |
| | | item.top = 0 |
| | | } else if (item.top + this.elementHeight + 80 > window.innerHeight) { |
| | | item.top = window.innerHeight- this.elementHeight |
| | | } |
| | | if (item.left < 0) { |
| | | item.left = 0 |
| | | } else if (item.left + this.elementWidth > window.innerWidth) { |
| | | item.left = window.innerWidth - this.elementWidth |
| | | } |
| | | } |
| | | }) |
| | | this.mouseX = event.clientX |
| | | this.mouseY = event.clientY |
| | | } |
| | | }, |
| | | /** |
| | | * ææ¡£å¯¹è±¡é¼ æ æé®å¼¹èµ·äºä»¶ |
| | | * @param event |
| | | */ |
| | | handleMouseUp(event) { |
| | | this.dragging = false |
| | | document.removeEventListener('mousemove', this.handleMouseMove) |
| | | document.removeEventListener('mouseup', this.handleMouseUp) |
| | | }, |
| | | /** |
| | | * ç¹å»ä¿åæé®è°ç¨æ¥å£ä¿åææ½åçä½ç½® |
| | | */ |
| | | saveDevicePositionByApi() { |
| | | console.log('ä¿åä½ç½®') |
| | | |
| | | } |
| | | }, |
| | | mounted() { |
| | | // ç¦æ¢ç¨æ·éä¸å
容 |
| | | document.onselectstart = () => false |
| | | }, |
| | | created() { |
| | | if (this.$route.params.workshopId) { |
| | | this.getDeviceListByApi(this.$route.params.workshopId) |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style scoped lang="less"> |
| | | .full-screen-container { |
| | | background-image: url('../assets/Bj.jpg'); |
| | | background-size: 100% 100%; |
| | | color: #fff; |
| | | |
| | | .page-header { |
| | | height: 80px; |
| | | font-size: 50px; |
| | | text-align: center; |
| | | position: relative; |
| | | .header-right { |
| | | position: absolute; |
| | | right: 200px; |
| | | top: 0; |
| | | } |
| | | } |
| | | |
| | | .content-container { |
| | | position: relative; |
| | | .single-device { |
| | | position: absolute; |
| | | border: 1px solid transparent; |
| | | padding: 10px; |
| | | display: flex; |
| | | flex-direction: column; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | | cursor: default; |
| | | &:active { |
| | | border: 1px solid #00b3ff; |
| | | } |
| | | .device-status { |
| | | width: 145px; |
| | | display: flex; |
| | | justify-content: space-between; |
| | | } |
| | | .device-id { |
| | | font-size: 20px; |
| | | } |
| | | /*.device-info {*/ |
| | | /*width: 100%;*/ |
| | | /*display: flex;*/ |
| | | /*align-items: center;*/ |
| | | /*justify-content: space-between;*/ |
| | | /*.status-square {*/ |
| | | /*width: 14px;*/ |
| | | /*height: 14px;*/ |
| | | /*border: 1px solid #fff;*/ |
| | | /*border-radius: 2px;*/ |
| | | /*}*/ |
| | | /*}*/ |
| | | } |
| | | } |
| | | } |
| | | </style> |
| | |
| | | <!--<!–<a-radio :value="3">ä»»å¡è¡¨æ ¼</a-radio>–>--> |
| | | <!--<!–</a-radio-group>–>--> |
| | | <!--</div>--> |
| | | <a-button type="primary" @click="navigateToTestWorkshop">è·³è½¬è³æµè¯è½¦é´</a-button> |
| | | <a-button type="primary" size="large" v-for="item in workshopList" :key="item.workshopId" |
| | | @click="navigateToWorkshopSignage(item.workshopId)">{{item.workshopName}} |
| | | </a-button> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import IndexChart from './IndexChart' |
| | | import IndexTask from "./IndexTask" |
| | | import IndexTask from './IndexTask' |
| | | import IndexBdc from './IndexBdc' |
| | | |
| | | export default { |
| | | name: "Analysis", |
| | | name: 'Analysis', |
| | | components: { |
| | | IndexChart, |
| | | IndexTask, |
| | |
| | | }, |
| | | data() { |
| | | return { |
| | | indexStyle:1 |
| | | indexStyle: 1, |
| | | workshopList: [ |
| | | { |
| | | workshopName: 'é¿æ²è½¦é´', |
| | | workshopId: '5321' |
| | | }, |
| | | { |
| | | workshopName: '天津车é´', |
| | | workshopId: '6312' |
| | | }, |
| | | { |
| | | workshopName: 'æ¦æ±è½¦é´', |
| | | workshopId: '3463' |
| | | }, |
| | | { |
| | | workshopName: 'å京车é´', |
| | | workshopId: '8421' |
| | | } |
| | | ] |
| | | } |
| | | }, |
| | | created() { |
| | | |
| | | }, |
| | | methods: { |
| | | navigateToTestWorkshop(){ |
| | | const url=this.$router.resolve('/testWorkshop').href |
| | | navigateToWorkshopSignage(workshopId) { |
| | | const url = this.$router.resolve(`/workshopSignage/${workshopId}`).href |
| | | window.open(url,'_blank') |
| | | } |
| | | } |
| | |
| | | <template> |
| | | <a-card :bordered="false" class="device_list"> |
| | | <div :bordered="false" class="device_list"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div style="width: 100%; background-color: #fff" class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | |
| | | <holiday-management-modal ref="modalForm" @ok="modalFormOk"></holiday-management-modal> |
| | | <holiday-management-modal-edit ref="modalFormedit" @ok="modalFormOk"></holiday-management-modal-edit> |
| | | |
| | | </a-card> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | |
| | | <template> |
| | | <a-card :bordered="false" class="device_list"> |
| | | <div :bordered="false" class="device_list"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div style="width: 100%; background-color: #fff" class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | |
| | | <!--<device-repair-model-add ref="modalFormadd" @ok="modalFormOk"></device-repair-model-add>--> |
| | | <!--<device-repair-model-edit ref="modalFormedit" @ok="modalFormOk"></device-repair-model-edit>--> |
| | | <!--<repair-model ref="repairModelFrom" @ok="modalFormOk"></repair-model>--> |
| | | |
| | | </a-card> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | |
| | | <template> |
| | | <a-card :bordered="false" class="device_list"> |
| | | <div :bordered="false" class="device_list"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div style="width: 100%; background-color: #fff" class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | |
| | | <!--<device-repair-model-edit ref="modalFormedit" @ok="modalFormOk"></device-repair-model-edit>--> |
| | | <!--<repair-model ref="repairModelFrom" @ok="modalFormOk"></repair-model>--> |
| | | |
| | | </a-card> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | |
| | | <template> |
| | | <a-card :bordered="false" class="device_list"> |
| | | <div :bordered="false" class="device_list"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div style="width: 100%; background-color: #fff" class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | |
| | | <plan-downtime-maintenance-modal ref="modalForm" @ok="modalFormOk"></plan-downtime-maintenance-modal> |
| | | <plan-downtime-maintenance-modal-edit ref="modalFormedit" @ok="modalFormOk"></plan-downtime-maintenance-modal-edit> |
| | | |
| | | </a-card> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | |
| | | <template> |
| | | <div class="efficiency_list" style="width: 100%;height: 100%;"> |
| | | <a-card :bordered="false"> |
| | | <div :bordered="false" style="height: 100%"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | |
| | | <div id="MdcEquipmentWarningLine" style="height: 100%;width: 65%;"></div> |
| | | </div> |
| | | </div> |
| | | </a-card> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | <template> |
| | | <a-card :bordered="false" class="device_list"> |
| | | <div :bordered="false" class="device_list"> |
| | | <div class="com_box"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div style="width: 100%; background-color: #fff" class="table-page-search-wrapper"> |
| | |
| | | </div> |
| | | <!-- tableåºå-end --> |
| | | </div> |
| | | </a-card> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | |
| | | <template> |
| | | <div class="deviceCalendar_list"> |
| | | <a-card :bordered="false"> |
| | | <div :bordered="false"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | |
| | | <div> |
| | |
| | | </a-table> |
| | | </div> |
| | | <device-calendar-model ref="modalForm" @ok="modalFormOk"></device-calendar-model> |
| | | </a-card> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | </a-col> |
| | | <a-col :md="6" :sm="6"> |
| | | <a-form-item label="æ¥æ"> |
| | | <a-date-picker v-model="queryParams.collectTime" :disabledDate="disabledDate" @change="dataChange" format='YYYY-MM-DD'/> |
| | | <a-date-picker v-model="queryParams.collectTime" :disabledDate="disabledDate" @change="dataChange" |
| | | format='YYYY-MM-DD'/> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :md="3" :sm="3"> |
| | |
| | | </a-tabs> |
| | | </div> |
| | | </div> |
| | | <work-chart-model ref="workChartModel"></work-chart-model> |
| | | <work-chart-model ref="workChartModel" :collectTime="this.queryParams.collectTime" |
| | | :equipment="this.equipment"></work-chart-model> |
| | | <work-history-model ref="workHistoryModel"></work-history-model> |
| | | </div> |
| | | </template> |
| | |
| | | middleTime: '', |
| | | queryParam:{}, |
| | | queryParams: { |
| | | collectTime:undefined, |
| | | collectTime: undefined |
| | | }, |
| | | loadingstayus:false, |
| | | loadingrunStatus:false, |
| | |
| | | }, |
| | | disabledDate(current){ |
| | | //Can not slect days before today and today |
| | | return current && current > moment().subtract('days', 0); |
| | | return current && current > moment().subtract('days', 0) |
| | | }, |
| | | queryChart() { |
| | | // this.normal = [] |
| | | // this.waring = [] |
| | | this.loadingstayus = true; |
| | | this.loadingrunStatus = true; |
| | | this.loadingstayus = true |
| | | this.loadingrunStatus = true |
| | | this.loadingwarnStatus = true |
| | | getAction(this.url.list, this.queryParams).then((res) => { |
| | | this.normalList = [] |
| | | this.waringList = [] |
| | | this.runList = [] |
| | | this.loadingstayus = false; |
| | | this.loadingrunStatus = false; |
| | | this.loadingstayus = false |
| | | this.loadingrunStatus = false |
| | | this.loadingwarnStatus = false |
| | | this.normal = [] |
| | | this.waring = [] |
| | |
| | | if(!this.queryParams.equipmentId||!this.queryParams.equipmentName){ |
| | | this.$notification.warning({ |
| | | message:'æ¶æ¯', |
| | | description:"è¯·éæ©è®¾å¤" |
| | | }); |
| | | description: 'è¯·éæ©è®¾å¤' |
| | | }) |
| | | return false |
| | | } |
| | | this.queryChart() |
| | |
| | | console.log('触åæç¤º') |
| | | this.$notification.warning({ |
| | | message:'æ¶æ¯', |
| | | description:"è¯·éæ©æ¶é´" |
| | | }); |
| | | description: 'è¯·éæ©æ¶é´' |
| | | }) |
| | | } |
| | | // this.queryList() |
| | | }, |
| | |
| | | // this.$message.warning("è¯·éæ©è®¾å¤è¿è¡æ¥è¯¢") |
| | | this.$notification.warning({ |
| | | message:'æ¶æ¯', |
| | | description:"è¯·éæ©è®¾å¤è¿è¡æ¥è¯¢" |
| | | }); |
| | | description: 'è¯·éæ©è®¾å¤è¿è¡æ¥è¯¢' |
| | | }) |
| | | }else{ |
| | | // 夿æ¯å¦ç¹å»è®¾å¤æ¥å¿è¡¨æ ¼è¡çæ°æ®ï¼æ¤æ¶ä¸ºç¹å»è¡¨æ ¼æ°æ®ä¸ºfalse |
| | | this.$refs.workChartModel.isClicklogListRow = false |
| | | this.$refs.workChartModel.add(this.equipment) |
| | | this.$refs.workChartModel.title = '工使²çº¿' |
| | | } |
| | | |
| | | }, |
| | | openHistoryChart() { |
| | | // console.log(this.equipment); |
| | |
| | | // this.$message.warning("è¯·éæ©è®¾å¤è¿è¡æ¥è¯¢") |
| | | this.$notification.warning({ |
| | | message:'æ¶æ¯', |
| | | description:"è¯·éæ©è®¾å¤è¿è¡æ¥è¯¢" |
| | | }); |
| | | description: 'è¯·éæ©è®¾å¤è¿è¡æ¥è¯¢' |
| | | }) |
| | | // console.log(1111) |
| | | } else{ |
| | | this.$refs.workHistoryModel.add(this.equipment) |
| | |
| | | this.$notification.warning({ |
| | | message:'æ¶æ¯', |
| | | description:'è¯·éæ©ä»å¤©ä»¥åä»å¤©ä¹åçæ¥æï¼ï¼' |
| | | }); |
| | | }) |
| | | }else{ |
| | | this.queryParams.collectTime = moment(this.queryParams.collectTime.add(1, 'd'), 'YYYY-MM-DD') |
| | | this.searchQuery() |
| | |
| | | _this.$notification.warning({ |
| | | message:'æ¶æ¯', |
| | | description:'请è系管çåï¼å¼æ¾è®¾å¤æéï¼' |
| | | }); |
| | | }) |
| | | } |
| | | }else{ |
| | | // this.$message.warning(res.message) |
| | | _this.$notification.warning({ |
| | | message:'æ¶æ¯', |
| | | description:res.message |
| | | }); |
| | | }) |
| | | |
| | | } |
| | | }) |
| | |
| | | created() { |
| | | this.queryParams.collectTime = moment() |
| | | this.queryParams.collectTimeStr = this.queryParams.collectTime.format('YYYY-MM-DD') |
| | | this.initEquipment(); |
| | | this.initEquipment() |
| | | // this.queryTreeData(); |
| | | }, |
| | | watch: { |
| | | equement(val) { |
| | | console.log('éè¿watch触å') |
| | | |
| | | if (val && val.equipmentId) { |
| | | this.$set(this.queryParams, 'equipmentName', val.equipmentName) |
| | | this.$set(this.queryParams, 'equipmentId', val.equipmentId) |
| | |
| | | #mdcLogShow > div { |
| | | flex: 1; |
| | | } |
| | | |
| | | /*.mdcLogShowOne{*/ |
| | | /*position: absolute;*/ |
| | | /*}*/ |
| | |
| | | <!-- tableåºå-begin --> |
| | | <div class="table_logList"> |
| | | <a-table ref="table" bordered size="middle" :rowKey="(record,index)=>{return index}" :columns="columns" |
| | | :dataSource="dataList" :pagination="ipagination" :loading="loadingequip" @change="handleTableChange"> |
| | | :dataSource="dataList" :pagination="ipagination" :loading="loadingequip" @change="handleTableChange" :customRow="rowClick"> |
| | | <template slot="status" slot-scope="status"> |
| | | <div v-if="status == '3' || status == '23'" style="color: #00ee00;width: 100%; height: 100%;">è¿è¡</div> |
| | | <div v-else-if="status == '1' || status == '2'" style="color: #ffea91;width: 100%; height: 100%;">å¾
æº</div> |
| | |
| | | import { |
| | | JeecgListMixin |
| | | } from '@/mixins/JeecgListMixin' |
| | | import moment from 'moment' |
| | | export default { |
| | | name: 'LogList', |
| | | mixins: [JeecgListMixin], |
| | |
| | | this.ipagination = pagination; |
| | | // this.loadData(); |
| | | }, |
| | | /** |
| | | * ç»è®¾å¤æ¥å¿è¡¨æ ¼ä¸çè¡æ·»å ç¹å»äºä»¶ |
| | | * @param record ç¹å»çå½åè¡æ°æ® |
| | | * @returns {{on: {click: on.click}}} æ·»å äºä»¶å¯¹è±¡ |
| | | */ |
| | | rowClick(record){ |
| | | return { |
| | | on:{ |
| | | click:()=>{ |
| | | const timeObj={ |
| | | start:moment(record.startTime), |
| | | end:moment(record.endTime) |
| | | } |
| | | this.$bus.$emit('tableRowRecord',timeObj) |
| | | } |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | created() { |
| | | } |
| | |
| | | <template> |
| | | <div ref="workChart"> |
| | | <a-modal :title="title" :getContainer="() => this.$refs.workChart" width="80%" wrap-class-name="full-modal" :footer="null" :visible="visible" |
| | | <a-modal :title="title" :getContainer="() => this.$refs.workChart" width="80%" wrap-class-name="full-modal" |
| | | :footer="null" :visible="visible" |
| | | @cancel="handleCancel" cancelText="å
³é"> |
| | | <div> |
| | | <div> |
| | |
| | | export default { |
| | | name: 'WorkChartModel', |
| | | components: {}, |
| | | props: {}, |
| | | props: { |
| | | collectTime: { |
| | | type: Object |
| | | }, |
| | | equipment: { |
| | | type: Object |
| | | } |
| | | }, |
| | | watch: { |
| | | // çæ§ç¶ç»ä»¶ç¹å»å·¦å³ç®å¤´åæ¢çæ¶é´å¼å°å
¶èµç»ç¹å»å·¥ä½æ²çº¿åçæ¶é´éæ©å¨çå¼ |
| | | collectTime: { |
| | | handler(newVal) { |
| | | this.currentToggledTime = newVal |
| | | } |
| | | } |
| | | }, |
| | | data() { |
| | | return { |
| | | spinning:false, |
| | |
| | | url: { |
| | | initPlainOptions: '/mdc/mdcDriveTypeParamConfig/findWorkCurveParamList', |
| | | workChart: '/mdc/mdcEquipmentRunningSection/workChart' |
| | | } |
| | | }, |
| | | currentToggledTime: '', |
| | | isClicklogListRow: false |
| | | } |
| | | }, |
| | | created() { |
| | | this.$bus.$on('tableRowRecord', this.getLogListRowRecord) |
| | | }, |
| | | mounted() { |
| | | |
| | | }, |
| | | methods: { |
| | | disabledDate(current){ |
| | | //Can not slect days before today and today |
| | | return current && current > moment().endOf("day"); |
| | | return current && current > moment().endOf('day') |
| | | }, |
| | | initPlainOptions(param) { |
| | | let that = this |
| | |
| | | temp.push({ label: item.chineseName, value: item.id, englishName: item.englishName }) |
| | | } |
| | | that.plainOptions = temp |
| | | |
| | | if(temp.length>0){ |
| | | that.option = [temp[0].value] |
| | | let param = { |
| | | driveType: that.node.driveType, |
| | | equipmentId: that.node.equipmentId, |
| | | date: that.queryParams.paramDateStr, |
| | | start: that.queryParams.startStr, |
| | | end: that.queryParams.endStr, |
| | | interval: that.queryParams.period, |
| | | codeTypeId: that.option.join(',') |
| | | } |
| | | that.initChart(param) |
| | | } |
| | | } |
| | | }) |
| | |
| | | end: this.queryParams.endStr, interval: this.queryParams.period, |
| | | codeTypeId: this.option.join(',') |
| | | } |
| | | this.initChart(param); |
| | | this.spinning = true; |
| | | this.initChart(param) |
| | | this.spinning = true |
| | | }, |
| | | timeHandleChange(val) { |
| | | if (val == 'start') { |
| | |
| | | let _this = this |
| | | this.visible = true |
| | | this.node = node |
| | | let paramDate = moment() |
| | | let start = moment('0:0', 'HH:mm') |
| | | let end = moment(moment().format('HH:mm'), 'HH:mm') |
| | | this.spinning = true |
| | | let paramDate |
| | | let start |
| | | let end |
| | | // 彿²¡æåæ¢è¿æ¶é´currentToggledTimeçå¼ä¸ºç©ºå¼ï¼å¦æç±äºç¹å»å·¦å³ç®å¤´åæ¢è¿æ¶é´ï¼åcurrentToggledTimeä¸ºåæ¢åçæ¶é´ |
| | | if (!this.currentToggledTime) { |
| | | paramDate = moment() |
| | | } else { |
| | | paramDate = this.currentToggledTime |
| | | } |
| | | // 夿æ¯å¦ç¹å»è®¾å¤æ¥å¿è¡¨æ ¼è¡çæ°æ®ï¼è¥ç¹å»è¡¨æ ¼æ°æ®åæ¾ç¤ºè¡¨æ ¼æ°æ®ä¸çæ¶é´ï¼è¥ç¹å»å·¥ä½æ²çº¿å¾çåæ¾ç¤º0ç¹è³å½åæ¶é´æ°æ® |
| | | if (this.isClicklogListRow) { |
| | | start = node.start |
| | | end = node.end |
| | | } else { |
| | | start = moment('0:0', 'HH:mm') |
| | | end = moment(moment().format('HH:mm'), 'HH:mm') |
| | | } |
| | | this.queryParams = { |
| | | equipmentId: node.equipmentId, |
| | | equipmentName: node.equipmentName, |
| | |
| | | } |
| | | this.$nextTick(() => { |
| | | _this.initPlainOptions(node) |
| | | let param = { |
| | | driveType: node.driveType, equipmentId: node.equipmentId, |
| | | date: _this.queryParams.paramDateStr, start: _this.queryParams.startStr, |
| | | end: _this.queryParams.endStr, interval: _this.queryParams.period, |
| | | codeTypeId: _this.option.join(',') |
| | | } |
| | | _this.initChart(param) |
| | | }) |
| | | }, |
| | | handleCancel() { |
| | | this.visible = false; |
| | | this.stratOpen = false; |
| | | this.endOpen = false; |
| | | this.visible = false |
| | | this.stratOpen = false |
| | | this.endOpen = false |
| | | }, |
| | | checkboxOnChange(e) { |
| | | if (e.length <= 3) { |
| | |
| | | this.$notification.warning({ |
| | | message:'æ¶æ¯', |
| | | description:'æå¤åªè½éæ©ä¸ä¸ª' |
| | | }); |
| | | }) |
| | | return false |
| | | } |
| | | }, |
| | |
| | | this.show = false |
| | | }, |
| | | getYAxisOffset(index) { |
| | | return index * 50 + 10; |
| | | return index * 50 + 10 |
| | | }, |
| | | initChart(param) { |
| | | if (!this.workChart) { |
| | |
| | | } |
| | | }, |
| | | legend: { |
| | | data:[], |
| | | data: [] |
| | | }, |
| | | title: { |
| | | left: 'center', |
| | |
| | | position:'left', |
| | | boundaryGap: [0, '15%'], |
| | | axisLine:{ |
| | | show:true, |
| | | show: true |
| | | // lineStyle:{ |
| | | // color:'#000000' |
| | | // } |
| | |
| | | position:'left', |
| | | boundaryGap: [0, '15%'], |
| | | axisLine:{ |
| | | show:true, |
| | | show: true |
| | | // lineStyle:{ |
| | | // color:'#000000' |
| | | // } |
| | |
| | | position:'left', |
| | | boundaryGap: [0, '15%'], |
| | | axisLine:{ |
| | | show:true, |
| | | show: true |
| | | // lineStyle:{ |
| | | // color:'#000000' |
| | | // } |
| | | } |
| | | }, |
| | | } |
| | | ], |
| | | dataZoom: [ |
| | | { |
| | |
| | | type:'line', |
| | | data:[], |
| | | smooth:true, |
| | | symbol:'none', |
| | | symbol: 'none' |
| | | } |
| | | ] |
| | | } |
| | |
| | | this.$notification.warning({ |
| | | message:'æ¶æ¯', |
| | | description:'æ æ°æ®!' |
| | | }); |
| | | this.spinning = false; |
| | | }) |
| | | this.spinning = false |
| | | _this.workChart.setOption(option,true) |
| | | }else{ |
| | | this.spinning = false; |
| | | this.spinning = false |
| | | // debugger |
| | | let result = [] |
| | | let itemLine = [] |
| | | //yè½´æ°ç» |
| | | var Yarr = [] |
| | | var lengenddata = []; |
| | | var lengenddata = [] |
| | | for (let i = 0; i < temp.length; i++) { |
| | | let item = temp[i] |
| | | itemLine = [] |
| | |
| | | yAxisIndex:i, |
| | | boundaryGap: [0,'100%'] |
| | | } |
| | | Yarr.push(Yline); |
| | | Yarr.push(Yline) |
| | | var line ={ |
| | | name:item.label, |
| | | type:'line', |
| | |
| | | |
| | | data:itemLine |
| | | } |
| | | result.push(line); |
| | | result.push(line) |
| | | |
| | | } |
| | | // option.yAxis = Yarr; |
| | | option.series = result; |
| | | option.legend = lengenddata; |
| | | option.series = result |
| | | option.legend = lengenddata |
| | | // console.log(option); |
| | | _this.workChart.setOption(option,true) |
| | | window.addEventListener('resize', function() { |
| | |
| | | } |
| | | |
| | | }) |
| | | }, |
| | | /** |
| | | * è·åç¹å»è®¾å¤æ¥å¿è¡¨æ ¼è¡åä»å
å¼ç»ä»¶ä¼ æ¥çæ¶é´å¯¹è±¡ |
| | | * @param timeObj å½åè¡çå¼å§æ¶é´ä¸ç»ææ¶é´ç»æç对象 |
| | | */ |
| | | getLogListRowRecord(timeObj) { |
| | | // 夿æ¯å¦ç¹å»è®¾å¤æ¥å¿è¡¨æ ¼è¡çæ°æ®ï¼æ¤æ¶ä¸ºç¹å»è¡¨æ ¼æ°æ®ä¸ºtrue |
| | | this.isClicklogListRow = true |
| | | // åå¹¶ç¶ç»ä»¶ä¼ æ¥çå½å设å¤ä¿¡æ¯å¯¹è±¡ä¸å
å¼ç»ä»¶ä¼ æ¥çå½åè¡çæ¶é´å¯¹è±¡ |
| | | const newQueryParams = Object.assign(this.equipment, timeObj) |
| | | this.add(newQueryParams) |
| | | this.title = '工使²çº¿' |
| | | } |
| | | } |
| | | } |
| | |
| | | flex: 1; |
| | | } |
| | | } |
| | | |
| | | /deep/ .ant-modal{ |
| | | /*background-color: #000;*/ |
| | | /*color: #fff;*/ |
| | | } |
| | | |
| | | /deep/ .ant-modal-header{ |
| | | /*background-color: #000;*/ |
| | | } |
| | | |
| | | /deep/ .ant-modal-title{ |
| | | /*color: #fff;*/ |
| | | } |
| | | |
| | | /deep/ .ant-modal-close{ |
| | | color: #1191b0; |
| | | font-size: 24px; |
| | | } |
| | | |
| | | /deep/ .ant-modal-content{ |
| | | /*background: -moz-linear-gradient(left, rgba(0, 0, 0, 0.66) 0%, rgba(0, 0, 0, 0.27) 100%);*/ |
| | | /*background: -webkit-gradient(linear, left left, right right, color-stop(0%, rgba(0, 0, 0, 0.66)), color-stop(100%, rgba(0, 0, 0, 0.4)));*/ |
| | |
| | | /*color: #fff;*/ |
| | | position: relative; |
| | | } |
| | | |
| | | /deep/ .ant-modal-header{ |
| | | /*border-bottom: none!important;*/ |
| | | } |
| | | |
| | | /deep/ .ant-checkbox-wrapper{ |
| | | /*color: #fff;*/ |
| | | } |
| | | |
| | | /deep/ .ant-form-item-label label{ |
| | | /*color: #fff;*/ |
| | | } |
| | | |
| | | /deep/ .ant-btn{ |
| | | /*position: absolute;*/ |
| | | |
| | | } |
| | | |
| | | .checkboxgroup{ |
| | | position: absolute; |
| | | right: 5%; |
| | |
| | | align-items: center; |
| | | flex-direction: column; |
| | | } |
| | | |
| | | /deep/ .ant-checkbox-group{ |
| | | display: flex; |
| | | flex-direction: column; |
| | | } |
| | | |
| | | /deep/ .ant-checkbox-group .ant-checkbox-wrapper{ |
| | | padding: 10px; |
| | | } |
| | |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .workChart_params{ |
| | | display: flex; |
| | | /*align-items: center;*/ |
| | | flex-direction: column; |
| | | float: left; |
| | | } |
| | | |
| | | .workChart_params .params_one{ |
| | | display: flex; |
| | | justify-content: space-between; |
| | | } |
| | | |
| | | .workChart_params .params_two{ |
| | | display: flex; |
| | | justify-content: space-between; |
| | | } |
| | | |
| | | /deep/ .workChart_params .ant-form-item{ |
| | | display: flex; |
| | | } |
| | | |
| | | /deep/ .workChart_params .ant-form-item .ant-form-item-control-wrapper{ |
| | | margin: 0 10px; |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | .ant-btn { |
| | | padding: 0 10px; |
| | |
| | | <template> |
| | | <a-card :bordered="false" class="device_list"> |
| | | <div :bordered="false" class="device_list"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div style="width: 100%; background-color: #fff" class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | |
| | | <!--<device-repair-model-add ref="modalFormadd" @ok="modalFormOk"></device-repair-model-add>--> |
| | | <device-repair-model-edit ref="modalFormedit" @ok="modalFormOk"></device-repair-model-edit> |
| | | <!--<repair-model ref="repairModelFrom" @ok="modalFormOk">0</repair-model>--> |
| | | </a-card> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | |
| | | <template> |
| | | <div style="width: 100%;"> |
| | | <a-card :bordered="false"> |
| | | <div :bordered="false"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | |
| | | </a-row> |
| | | </a-form> |
| | | </div> |
| | | <div style="width: 530px;position: absolute;top: 20px; right:1.5%;"> |
| | | <div style="width: 530px;position: absolute;top: 0; right:1.5%;"> |
| | | <table cellpadding="5" cellspacing="1" style="border: 1px solid darkgray;"> |
| | | <tr> |
| | | <td v-for="(item, index) in identifying">{{item.title}}</td> |
| | |
| | | </table> |
| | | </div> |
| | | </div> |
| | | </a-card> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | <template> |
| | | <div class="efficiency_list" style="width: 100%"> |
| | | <a-card :bordered="false"> |
| | | <div :bordered="false"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div> |
| | | <div class="table-page-search-wrapper"> |
| | |
| | | </a-row> |
| | | </a-form> |
| | | </div> |
| | | <div style="width: 530px;position: absolute;top: 20px; right: 1.5%;"> |
| | | <div style="width: 530px;position: absolute;top: 0; right: 1.5%;"> |
| | | <table cellpadding="5" cellspacing="1" style="border: 1px solid darkgray;"> |
| | | <tr> |
| | | <td v-for="(item, index) in identifying">{{item.title}}</td> |
| | |
| | | </table> |
| | | </div> |
| | | </div> |
| | | </a-card> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | <template> |
| | | <div style="width: 100%;"> |
| | | <a-card :bordered="false"> |
| | | <div :bordered="false"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div class="seach-content"> |
| | | <div class="table-page-search-wrapper"> |
| | |
| | | </a-row> |
| | | </a-form> |
| | | </div> |
| | | <div style="width: 530px;top: 20px; right: 0px;"> |
| | | <div style="width: 530px;top: 0; right: 0px;"> |
| | | <table cellpadding="5" cellspacing="1" style="border: 1px solid darkgray;"> |
| | | <tr> |
| | | <td v-for="(item, index) in identifying">{{item.title}}</td> |
| | |
| | | </table> |
| | | </div> |
| | | </div> |
| | | </a-card> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | <template> |
| | | <a-spin :spinning="loading"> |
| | | <a-card :bordered="false" class="device_list"> |
| | | <div :bordered="false" class="device_list"> |
| | | <div class="com_box"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div style="width: 100%; background-color: #fff" class="table-page-search-wrapper"> |
| | |
| | | </div> |
| | | <!-- tableåºå-end --> |
| | | </div> |
| | | </a-card> |
| | | </div> |
| | | </a-spin> |
| | | </template> |
| | | |
| | |
| | | <template> |
| | | <a-card :bordered="false" class="device_list"> |
| | | <div :bordered="false" class="device_list"> |
| | | <div class="com_box"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div style="width: 100%; background-color: #fff" class="table-page-search-wrapper"> |
| | |
| | | </div> |
| | | <!-- tableåºå-end --> |
| | | </div> |
| | | </a-card> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | |
| | | <template> |
| | | <a-card :bordered="false" class="device_list"> |
| | | <div :bordered="false" class="device_list"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div style="width: 100%; background-color: #fff" class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | |
| | | <!--<device-repair-model></device-repair-model>--> |
| | | <mdc-pass-rate-modal ref="modalForm" @ok="modalFormOk"></mdc-pass-rate-modal> |
| | | <mdc-pass-rate-edit ref="modalFormedit" @ok="modalFormOk"></mdc-pass-rate-edit> |
| | | </a-card> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | |
| | | <template> |
| | | <a-card :bordered="false" class="device_list"> |
| | | <div :bordered="false" class="device_list"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div style="width: 100%; background-color: #fff" class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | |
| | | <mdc-process-quantity-modal ref="modalForm" @ok="modalFormOk"></mdc-process-quantity-modal> |
| | | <mdc-process-quantity-edit ref="modalFormedit" @ok="modalFormOk"></mdc-process-quantity-edit> |
| | | |
| | | </a-card> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | |
| | | <template> |
| | | <a-card :bordered="false" class="device_list"> |
| | | <div :bordered="false" class="device_list"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div style="width: 100%; background-color: #fff" class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | |
| | | <mdc-standard-process-duration-modal ref="modalForm" @ok="modalFormOk"></mdc-standard-process-duration-modal> |
| | | <mdc-standard-process-duration-edit ref="modalFormedit" @ok="modalFormOk"></mdc-standard-process-duration-edit> |
| | | |
| | | </a-card> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | |
| | | <template> |
| | | <div class="efficiency_list" style="width: 100%;height: 100%;"> |
| | | <a-card :bordered="false"> |
| | | <div :bordered="false" style="height: 100%"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | |
| | | </div> |
| | | <div id="openRateTrendChart" style="width: 100%;height: 60%"></div> |
| | | </div> |
| | | </a-card> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | <template> |
| | | <div class="efficiency_list" style="width: 100%;height: 100%;"> |
| | | <a-card :bordered="false"> |
| | | <div :bordered="false" style="height: 100%"> |
| | | <!-- æ¥è¯¢åºå --> |
| | | <div class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | |
| | | </div> |
| | | <div id="openRateTrendChart" style="width: 100%;height: 60%"></div> |
| | | </div> |
| | | </a-card> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | |