From b70dab217e5ebcab6d98196cc2d4b2ffb842c3a1 Mon Sep 17 00:00:00 2001 From: zhuzhuanzhuan Date: 星期日, 08 十月 2023 17:33:34 +0800 Subject: [PATCH] 1、优化车间看板四色灯状态展示以及限制拖拽区域 2、部分页面右侧区域元素位置离顶过高,调整布局 3、增加设备日志页面增加点击表格行数据展示当前行工作曲线功能 4、优化设备日志页面切换时间,工作曲线弹窗中的时间随之切换 5、优化设备日志页面加载后首次点击工作曲线后无法查询到数据问题(同时发送异步请求,先后顺序影响) --- src/views/mdc/base/modules/UnplannedDowntimemManager/UnplannedDowntimemManagerList.vue | 4 src/views/mdc/base/modules/openRateFractionAnalysis/openRateFractionAnalysisMain.vue | 4 src/views/mdc/base/modules/efficiencyReport/EfficiencyList.vue | 6 src/views/dashboard/Analysis.vue | 46 + src/views/mdc/base/modules/comparativeAnalysis/comparativeAnalysismain.vue | 4 src/views/mdc/base/modules/efficiencyShiftReport/EfficiencyShiftList.vue | 6 src/views/mdc/base/modules/equipmentAvailCompare/equipmentAvailCompareMain.vue | 4 src/config/router.config.js | 5 src/views/mdc/base/modules/deviceLog/LogInfo.vue | 115 ++-- src/views/mdc/base/modules/equipmentDayAvail/equipmentDayAvailMain.vue | 4 src/views/mdc/base/modules/mdcProcessQuantity/mdcProcessQuantityList.vue | 4 src/views/mdc/base/modules/deviceRepair/DeviceRepairList.vue | 4 src/views/mdc/base/modules/openRateTrendAnalysis/openRateTrendAnalysisMain.vue | 4 src/views/mdc/base/modules/deviceCalendar/DeviceCalendarList.vue | 4 src/views/mdc/base/modules/efficiencyPOReport/EfficiencyPOList.vue | 6 src/views/mdc/base/modules/TorqueconfigurationList/TorqueconfigurationList.vue | 4 src/views/mdc/base/modules/deviceLog/LogList.vue | 21 src/views/mdc/base/modules/OvertimeManagement/OvertimeManagementList.vue | 5 src/views/mdc/base/modules/mdcPassRate/mdcPassRateList.vue | 4 /dev/null | 180 ------- src/views/mdc/base/modules/mdcStandardProcessDuration/MdcStandardProcessDurationList.vue | 4 src/views/WorkshopSignage.vue | 243 +++++++++ src/views/mdc/base/modules/HolidayManagement/HolidayManagementList.vue | 4 src/views/mdc/base/modules/deviceLog/WorkChartModel.vue | 796 +++++++++++++++++-------------- src/views/mdc/base/modules/alarmAnalysis/alarmAnalysisMain.vue | 4 25 files changed, 827 insertions(+), 658 deletions(-) diff --git a/src/config/router.config.js b/src/config/router.config.js index e41fc6e..464cfb8 100644 --- a/src/config/router.config.js +++ b/src/config/router.config.js @@ -12,7 +12,6 @@ meta: { title: '棣栭〉' }, redirect: '/dashboard/analysis', children: [ - // // dashboard // { // path: '/dashboard', @@ -373,8 +372,8 @@ ] }, { - path:'/testWorkshop', - component:()=>import('@/views/TestWorkshop.vue') + path:'/workshopSignage/:workshopId', + component:()=>import('@/views/WorkshopSignage.vue') }, { path: '/404', diff --git a/src/views/TestWorkshop.vue b/src/views/TestWorkshop.vue deleted file mode 100644 index 717ae32..0000000 --- a/src/views/TestWorkshop.vue +++ /dev/null @@ -1,180 +0,0 @@ -<template> - <dv-full-screen-container class="full-screen-container"> - <header class="page-header"> - 娴嬭瘯杞﹂棿 - <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'}" @mousedown="handleMouseDown" :id="item.equipmentId"> - <img :src="item.equipmentImageUrl" draggable="false"> - <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> - </dv-border-box-8> - </dv-full-screen-container> -</template> - -<script> - export default { - data() { - return { - mouseX: 0, // 榧犳爣鍦ㄥ厓绱犲唴鐨刋鍧愭爣 - mouseY: 0, // 榧犳爣鍦ㄥ厓绱犲唴鐨刌鍧愭爣, - dragging: false, //鏄惁鍦ㄦ嫋鎷戒腑 - left: 0, // 鍏冪礌宸︿笂瑙掕窛绂荤埗瀹瑰櫒宸︿晶鐨勮窛绂� - top: 0, // 鍏冪礌宸︿笂瑙掕窛绂荤埗瀹瑰櫒椤堕儴鐨勮窛绂�, - elementId: '',// 琚嫋鎷藉厓绱犵殑id灞炴�у�� - deviceList: [ - { - equipmentId: '123213213123232', - equipmentStatus: 0, - equipmentImageUrl: require('../assets/8.png'), - top: 200, - left: 100, - status: 1 - }, - { - equipmentId: '512346789561232', - equipmentStatus: 0, - equipmentImageUrl: require('../assets/8.png'), - top: 500, - left: 753, - status: 0 - }, - { - equipmentId: '64746965647653', - equipmentStatus: 0, - equipmentImageUrl: require('../assets/8.png'), - top: 300, - left: 860, - status: 2 - }, - { - equipmentId: '33548976965462', - equipmentStatus: 0, - equipmentImageUrl: require('../assets/8.png'), - top: 100, - left: 380, - status: 3 - }, - { - equipmentId: '85484913549253', - equipmentStatus: 0, - equipmentImageUrl: require('../assets/8.png'), - top: 200, - left: 1500, - status: 2 - } - ] - } - }, - methods: { - /** - * 鎷栨嫿瀵硅薄榧犳爣鎸夐敭鎸変笅浜嬩欢 - * @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) - }, - /** - * 鏂囨。瀵硅薄榧犳爣绉诲姩浜嬩欢 - * @param event - */ - handleMouseMove(event) { - if (this.dragging) { - const deltaX = event.clientX - this.mouseX - 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 - } - }) - 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(){ - - } - }, - mounted() { - // 绂佹鐢ㄦ埛閫変腑鍐呭 - document.onselectstart = () => false - } - } -</script> - -<style scoped lang="less"> - .full-screen-container { - background-image: url('../assets/Bj.jpg'); - color: #fff; - width: 100vw; - height: 100vh; - position: relative; - .page-header { - font-size: 50px; - text-align: center; - position: relative; - .header-right{ - position: absolute; - right: 200px; - top: 0; - } - } - .content-container { - .single-device { - position: absolute; - border: 1px solid transparent; - padding: 5px; - display: flex; - flex-direction: column; - align-items: center; - &:active { - border: 1px solid #00b3ff; - } - .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> \ No newline at end of file diff --git a/src/views/WorkshopSignage.vue b/src/views/WorkshopSignage.vue new file mode 100644 index 0000000..cddcdfe --- /dev/null +++ b/src/views/WorkshopSignage.vue @@ -0,0 +1,243 @@ +<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, // 榧犳爣鍦ㄥ厓绱犲唴鐨刋鍧愭爣 + mouseY: 0, // 榧犳爣鍦ㄥ厓绱犲唴鐨刌鍧愭爣, + 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 + // 闄愬埗鎷栨嫿瓒呭嚭鍖哄煙(缂╂斁娴忚鍣ㄧ獥鍙e悗璺濆洓鍛ㄨ窛绂诲嚭鐜伴棶棰�) + 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> \ No newline at end of file diff --git a/src/views/dashboard/Analysis.vue b/src/views/dashboard/Analysis.vue index 949a625..e0df30b 100644 --- a/src/views/dashboard/Analysis.vue +++ b/src/views/dashboard/Analysis.vue @@ -4,24 +4,26 @@ <!--<index-bdc v-if="indexStyle==2"></index-bdc>--> <!--<index-task v-if="indexStyle==3"></index-task>--> <!--<div style="width: 100%;text-align: right;margin-top: 20px">--> - <!--璇烽�夋嫨棣栭〉鏍峰紡锛�--> - <!--<!–<a-radio-group v-model="indexStyle">–>--> - <!--<!–<a-radio :value="1">缁熻鍥捐〃</a-radio>–>--> - <!--<!–<a-radio :value="2">缁熻鍥捐〃2</a-radio>–>--> - <!--<!–<a-radio :value="3">浠诲姟琛ㄦ牸</a-radio>–>--> - <!--<!–</a-radio-group>–>--> + <!--璇烽�夋嫨棣栭〉鏍峰紡锛�--> + <!--<!–<a-radio-group v-model="indexStyle">–>--> + <!--<!–<a-radio :value="1">缁熻鍥捐〃</a-radio>–>--> + <!--<!–<a-radio :value="2">缁熻鍥捐〃2</a-radio>–>--> + <!--<!–<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, @@ -29,16 +31,34 @@ }, 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 - window.open(url,'_blank') + navigateToWorkshopSignage(workshopId) { + const url = this.$router.resolve(`/workshopSignage/${workshopId}`).href + window.open(url, '_blank') } } } diff --git a/src/views/mdc/base/modules/HolidayManagement/HolidayManagementList.vue b/src/views/mdc/base/modules/HolidayManagement/HolidayManagementList.vue index 45c49f0..0884a23 100644 --- a/src/views/mdc/base/modules/HolidayManagement/HolidayManagementList.vue +++ b/src/views/mdc/base/modules/HolidayManagement/HolidayManagementList.vue @@ -1,5 +1,5 @@ <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"> @@ -79,7 +79,7 @@ <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> diff --git a/src/views/mdc/base/modules/OvertimeManagement/OvertimeManagementList.vue b/src/views/mdc/base/modules/OvertimeManagement/OvertimeManagementList.vue index df8712a..e7b5e18 100644 --- a/src/views/mdc/base/modules/OvertimeManagement/OvertimeManagementList.vue +++ b/src/views/mdc/base/modules/OvertimeManagement/OvertimeManagementList.vue @@ -1,5 +1,5 @@ <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"> @@ -83,8 +83,7 @@ <!--<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> diff --git a/src/views/mdc/base/modules/TorqueconfigurationList/TorqueconfigurationList.vue b/src/views/mdc/base/modules/TorqueconfigurationList/TorqueconfigurationList.vue index aff3728..1d0f25a 100644 --- a/src/views/mdc/base/modules/TorqueconfigurationList/TorqueconfigurationList.vue +++ b/src/views/mdc/base/modules/TorqueconfigurationList/TorqueconfigurationList.vue @@ -1,5 +1,5 @@ <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"> @@ -83,7 +83,7 @@ <!--<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> diff --git a/src/views/mdc/base/modules/UnplannedDowntimemManager/UnplannedDowntimemManagerList.vue b/src/views/mdc/base/modules/UnplannedDowntimemManager/UnplannedDowntimemManagerList.vue index a7ca61e..ed8b56e 100644 --- a/src/views/mdc/base/modules/UnplannedDowntimemManager/UnplannedDowntimemManagerList.vue +++ b/src/views/mdc/base/modules/UnplannedDowntimemManager/UnplannedDowntimemManagerList.vue @@ -1,5 +1,5 @@ <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"> @@ -81,7 +81,7 @@ <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> diff --git a/src/views/mdc/base/modules/alarmAnalysis/alarmAnalysisMain.vue b/src/views/mdc/base/modules/alarmAnalysis/alarmAnalysisMain.vue index ec4ca0b..b602fd4 100644 --- a/src/views/mdc/base/modules/alarmAnalysis/alarmAnalysisMain.vue +++ b/src/views/mdc/base/modules/alarmAnalysis/alarmAnalysisMain.vue @@ -1,6 +1,6 @@ <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"> @@ -52,7 +52,7 @@ <div id="MdcEquipmentWarningLine" style="height: 100%;width: 65%;"></div> </div> </div> - </a-card> + </div> </div> </template> diff --git a/src/views/mdc/base/modules/comparativeAnalysis/comparativeAnalysismain.vue b/src/views/mdc/base/modules/comparativeAnalysis/comparativeAnalysismain.vue index 8142dcc..9f19ba1 100644 --- a/src/views/mdc/base/modules/comparativeAnalysis/comparativeAnalysismain.vue +++ b/src/views/mdc/base/modules/comparativeAnalysis/comparativeAnalysismain.vue @@ -1,5 +1,5 @@ <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"> @@ -53,7 +53,7 @@ </div> <!-- table鍖哄煙-end --> </div> - </a-card> + </div> </template> <script> diff --git a/src/views/mdc/base/modules/deviceCalendar/DeviceCalendarList.vue b/src/views/mdc/base/modules/deviceCalendar/DeviceCalendarList.vue index 47997ea..b653554 100644 --- a/src/views/mdc/base/modules/deviceCalendar/DeviceCalendarList.vue +++ b/src/views/mdc/base/modules/deviceCalendar/DeviceCalendarList.vue @@ -1,6 +1,6 @@ <template> <div class="deviceCalendar_list"> - <a-card :bordered="false"> + <div :bordered="false"> <!-- 鏌ヨ鍖哄煙 --> <div> @@ -47,7 +47,7 @@ </a-table> </div> <device-calendar-model ref="modalForm" @ok="modalFormOk"></device-calendar-model> - </a-card> + </div> </div> </template> diff --git a/src/views/mdc/base/modules/deviceLog/LogInfo.vue b/src/views/mdc/base/modules/deviceLog/LogInfo.vue index 3bdc973..b3140ad 100644 --- a/src/views/mdc/base/modules/deviceLog/LogInfo.vue +++ b/src/views/mdc/base/modules/deviceLog/LogInfo.vue @@ -16,7 +16,8 @@ </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"> @@ -60,9 +61,9 @@ <span v-if="item.status == 23" :style='{display: "inline-block",width:item.dateProportion, height: "100%", background: "#19FE01",position:"absolute",bottom:"0"}'></span> </div> - <div v-if="item.status == 22" style="z-index: 999;" - :style='{display: "inline-block",left:item.left,width:item.dateProportion, height: "100%",position:"absolute"}' - v-for="item in waring"> + <div v-if="item.status == 22" style="z-index: 999;" + :style='{display: "inline-block",left:item.left,width:item.dateProportion, height: "100%",position:"absolute"}' + v-for="item in waring"> <span :style='{display: "inline-block",width:"100%", left:0, height: "68%", background: "#FD0008",position:"absolute",bottom:"0"}'></span> </div> @@ -150,7 +151,8 @@ </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> @@ -176,17 +178,17 @@ props: { equement: {} }, data() { return { - readOnly:true, + readOnly: true, defaultId: '', defaultName: '', middleTime: '', - queryParam:{}, + queryParam: {}, queryParams: { - collectTime:undefined, + collectTime: undefined }, - loadingstayus:false, - loadingrunStatus:false, - loadingwarnStatus:false, + loadingstayus: false, + loadingrunStatus: false, + loadingwarnStatus: false, normal: [], waring: [], normalList: [], @@ -200,7 +202,7 @@ getEquipmentByPid: '/mdc/mdcEquipment/getEquipmentByPid', list: '/mdc/mdcEquipmentRunningSection/logList' }, - ProStartId:'' + ProStartId: '' } }, methods: { @@ -223,27 +225,27 @@ tabChange(val) { this.activeKey = val }, - disabledDate(current){ + 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 (res.success) { - if(res.result != null){ + if (res.result != null) { for (let i = 0; i < res.result.length; i++) { this.normalList.push(res.result[i]) if ('22' == res.result[i].status) { @@ -253,11 +255,11 @@ res.result[i].left = leftTmp / 86400 * 100 + '%' this.waring.push(res.result[i]) - }else if('3' == res.result[i].status){ + } else if ('3' == res.result[i].status) { this.runList.push(res.result[i]) res.result[i].dateProportion = res.result[i].duration / 86400 * 100 + '%' this.normal.push(res.result[i]) - }else{ + } else { res.result[i].dateProportion = res.result[i].duration / 86400 * 100 + '%' this.normal.push(res.result[i]) // console.log(this.normal) @@ -324,23 +326,23 @@ }, searchQuery() { // console.log(this.queryParams.collectTime) - if(this.queryParams.collectTime != undefined){ + if (this.queryParams.collectTime != undefined) { this.queryParams.collectTimeStr = this.queryParams.collectTime.format('YYYY-MM-DD') - if(!this.queryParams.equipmentId||!this.queryParams.equipmentName){ + if (!this.queryParams.equipmentId || !this.queryParams.equipmentName) { this.$notification.warning({ - message:'娑堟伅', - description:"璇烽�夋嫨璁惧" - }); + message: '娑堟伅', + description: '璇烽�夋嫨璁惧' + }) return false } this.queryChart() - }else{ + } else { // this.$message.warning("璇烽�夋嫨鏃堕棿") console.log('瑙﹀彂鎻愮ず') this.$notification.warning({ - message:'娑堟伅', - description:"璇烽�夋嫨鏃堕棿" - }); + message: '娑堟伅', + description: '璇烽�夋嫨鏃堕棿' + }) } // this.queryList() }, @@ -354,28 +356,29 @@ // this.onClearSelected() }, openWorkChart() { - if(!this.equipment.equipmentId){ + if (!this.equipment.equipmentId) { // this.$message.warning("璇烽�夋嫨璁惧杩涜鏌ヨ") this.$notification.warning({ - message:'娑堟伅', - description:"璇烽�夋嫨璁惧杩涜鏌ヨ" - }); - }else{ + message: '娑堟伅', + description: '璇烽�夋嫨璁惧杩涜鏌ヨ' + }) + } else { + // 鍒ゆ柇鏄惁鐐瑰嚮璁惧鏃ュ織琛ㄦ牸琛岀殑鏁版嵁锛屾鏃朵负鐐瑰嚮琛ㄦ牸鏁版嵁涓篺alse + this.$refs.workChartModel.isClicklogListRow = false this.$refs.workChartModel.add(this.equipment) this.$refs.workChartModel.title = '宸ヤ綔鏇茬嚎' } - }, openHistoryChart() { // console.log(this.equipment); - if(!this.equipment.equipmentId){ + if (!this.equipment.equipmentId) { // this.$message.warning("璇烽�夋嫨璁惧杩涜鏌ヨ") this.$notification.warning({ - message:'娑堟伅', - description:"璇烽�夋嫨璁惧杩涜鏌ヨ" - }); + message: '娑堟伅', + description: '璇烽�夋嫨璁惧杩涜鏌ヨ' + }) // console.log(1111) - } else{ + } else { this.$refs.workHistoryModel.add(this.equipment) this.$refs.workHistoryModel.title = '鍘嗗彶鏃ュ織' } @@ -386,13 +389,13 @@ this.searchQuery() }, dataAfter() { - if((this.queryParams.collectTime).format('YYYY-MM-DD') == moment().format('YYYY-MM-DD')){ + if ((this.queryParams.collectTime).format('YYYY-MM-DD') == moment().format('YYYY-MM-DD')) { // this.$message.warning("璇烽�夋嫨浠婂ぉ浠ュ強浠婂ぉ涔嬪墠鐨勬棩鏈燂紒锛�") this.$notification.warning({ - message:'娑堟伅', - description:'璇烽�夋嫨浠婂ぉ浠ュ強浠婂ぉ涔嬪墠鐨勬棩鏈燂紒锛�' - }); - }else{ + message: '娑堟伅', + description: '璇烽�夋嫨浠婂ぉ浠ュ強浠婂ぉ涔嬪墠鐨勬棩鏈燂紒锛�' + }) + } else { this.queryParams.collectTime = moment(this.queryParams.collectTime.add(1, 'd'), 'YYYY-MM-DD') this.searchQuery() } @@ -413,16 +416,16 @@ this.equipment = {} // _this.$message.warning('璇疯仈绯荤鐞嗗憳锛屽紑鏀捐澶囨潈闄愶紒') _this.$notification.warning({ - message:'娑堟伅', - description:'璇疯仈绯荤鐞嗗憳锛屽紑鏀捐澶囨潈闄愶紒' - }); + message: '娑堟伅', + description: '璇疯仈绯荤鐞嗗憳锛屽紑鏀捐澶囨潈闄愶紒' + }) } - }else{ + } else { // this.$message.warning(res.message) _this.$notification.warning({ - message:'娑堟伅', - description:res.message - }); + message: '娑堟伅', + description: res.message + }) } }) @@ -431,13 +434,12 @@ 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) @@ -492,7 +494,8 @@ #mdcLogShow > div { flex: 1; } + /*.mdcLogShowOne{*/ - /*position: absolute;*/ + /*position: absolute;*/ /*}*/ </style> diff --git a/src/views/mdc/base/modules/deviceLog/LogList.vue b/src/views/mdc/base/modules/deviceLog/LogList.vue index a1a33bf..440c9af 100644 --- a/src/views/mdc/base/modules/deviceLog/LogList.vue +++ b/src/views/mdc/base/modules/deviceLog/LogList.vue @@ -3,7 +3,7 @@ <!-- 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> @@ -28,6 +28,7 @@ import { JeecgListMixin } from '@/mixins/JeecgListMixin' + import moment from 'moment' export default { name: 'LogList', mixins: [JeecgListMixin], @@ -154,6 +155,24 @@ 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() { } diff --git a/src/views/mdc/base/modules/deviceLog/WorkChartModel.vue b/src/views/mdc/base/modules/deviceLog/WorkChartModel.vue index 686e4f6..aefcf42 100644 --- a/src/views/mdc/base/modules/deviceLog/WorkChartModel.vue +++ b/src/views/mdc/base/modules/deviceLog/WorkChartModel.vue @@ -1,6 +1,7 @@ <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> @@ -12,7 +13,7 @@ </a-col> <a-col :span="6"> <a-form-item label="鏃ユ湡" :labelCol="labelCol" :wrapperCol="wrapperCol"> - <a-date-picker v-model="queryParams.paramDate" :disabledDate="disabledDate" format='YYYY-MM-DD'/> + <a-date-picker v-model="queryParams.paramDate" :disabledDate="disabledDate" format='YYYY-MM-DD'/> </a-form-item> </a-col> <a-col :span="6"> @@ -69,166 +70,206 @@ </template> <script> -import moment from 'moment' -import * as echarts from 'echarts' -import { - getAction, - postAction -} from '@/api/manage' -import { - duplicateCheck -} from '@/api/api' + import moment from 'moment' + import * as echarts from 'echarts' + import { + getAction, + postAction + } from '@/api/manage' + import { + duplicateCheck + } from '@/api/api' -export default { - name: 'WorkChartModel', - components: {}, - props: {}, - data() { - return { - spinning:false, - labelCol: { - xs: { - span: 24 - }, - sm: { - span: 6 - } + export default { + name: 'WorkChartModel', + components: {}, + props: { + collectTime: { + type: Object }, - wrapperCol: { - xs: { - span: 24 + equipment: { + type: Object + } + }, + watch: { + // 鐩戞帶鐖剁粍浠剁偣鍑诲乏鍙崇澶村垏鎹㈢殑鏃堕棿鍊煎皢鍏惰祴缁欑偣鍑诲伐浣滄洸绾垮悗鐨勬椂闂撮�夋嫨鍣ㄧ殑鍊� + collectTime: { + handler(newVal) { + this.currentToggledTime = newVal + } + } + }, + data() { + return { + spinning: false, + labelCol: { + xs: { + span: 24 + }, + sm: { + span: 6 + } }, - sm: { - span: 18 - } + wrapperCol: { + xs: { + span: 24 + }, + sm: { + span: 18 + } + }, + readOnly: true, + title: '', + plainOptions: [], + option: [], + workChart: '', + node: {}, + stratOpen: false, + endOpen: false, + visible: false, + show: false, + queryParams: {}, + panduanResult: [], + 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') }, - readOnly:true, - title: '', - plainOptions: [], - option: [], - workChart: '', - node: {}, - stratOpen: false, - endOpen: false, - visible: false, - show: false, - queryParams: {}, - panduanResult:[], - url: { - initPlainOptions: '/mdc/mdcDriveTypeParamConfig/findWorkCurveParamList', - workChart: '/mdc/mdcEquipmentRunningSection/workChart' - } - } - }, - mounted() { - }, - methods: { - disabledDate(current){ - //Can not slect days before today and today - return current && current > moment().endOf("day"); - }, - initPlainOptions(param) { - let that = this - let equipment = param.equipmentId - getAction(this.url.initPlainOptions,{equipmentId:equipment}).then((res) => { - if (res.success) { - let temp = [] - // debugger - for (var item of res.result) { - temp.push({ label: item.chineseName, value: item.id, englishName: item.englishName }) + initPlainOptions(param) { + let that = this + let equipment = param.equipmentId + getAction(this.url.initPlainOptions, { equipmentId: equipment }).then((res) => { + if (res.success) { + let temp = [] + // debugger + for (var item of res.result) { + 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) + } } - that.plainOptions = temp - if(temp.length>0){ - that.option = [temp[0].value] - } - } - }) - }, - searchQuery() { - this.queryParams.paramDateStr = this.queryParams.paramDate.format('yyyy-MM-DD') - this.queryParams.startStr = this.queryParams.start.format('HH:mm') - this.queryParams.endStr = this.queryParams.end.format('HH:mm') - let param = { - driveType: this.node.driveType, equipmentId: this.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); - this.spinning = true; - }, - timeHandleChange(val) { - if (val == 'start') { - this.stratOpen = true - } else { - this.endOpen = true - } - }, - timeHandleClose(val) { - if (val == 'start') { - this.stratOpen = false - this.endOpen = true - } else { - this.endOpen = false - } - }, - add(node) { - 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.queryParams = { - equipmentId: node.equipmentId, - equipmentName: node.equipmentName, - period: 1000, - paramDate: paramDate, - paramDateStr: paramDate.format('yyyy-MM-DD'), - start: start, - startStr: start.format('HH:mm'), - end: end, - endStr: end.format('HH:mm') - } - this.$nextTick(() => { - _this.initPlainOptions(node) + }) + }, + searchQuery() { + this.queryParams.paramDateStr = this.queryParams.paramDate.format('yyyy-MM-DD') + this.queryParams.startStr = this.queryParams.start.format('HH:mm') + this.queryParams.endStr = this.queryParams.end.format('HH:mm') 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(',') + driveType: this.node.driveType, equipmentId: this.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; - }, - checkboxOnChange(e) { - if (e.length <= 3) { - this.option = e - } else { - // this.$message.warn('鏈�澶氬彧鑳介�夋嫨3涓�') - this.$notification.warning({ - message:'娑堟伅', - description:'鏈�澶氬彧鑳介�夋嫨涓変釜' - }); - return false - } - }, - close() { - this.visible = false - this.show = false - }, - getYAxisOffset(index) { - return index * 50 + 10; - }, - initChart(param) { - if (!this.workChart) { - this.workChart = echarts.init(document.getElementById('workChart')) - } + this.initChart(param) + this.spinning = true + }, + timeHandleChange(val) { + if (val == 'start') { + this.stratOpen = true + } else { + this.endOpen = true + } + }, + timeHandleClose(val) { + if (val == 'start') { + this.stratOpen = false + this.endOpen = true + } else { + this.endOpen = false + } + }, + add(node) { + let _this = this + this.visible = true + this.node = node + this.spinning = true + let paramDate + let start + let end + // 褰撴病鏈夊垏鎹㈣繃鏃堕棿currentToggledTime鐨勫�间负绌哄�硷紝濡傛灉鐢变簬鐐瑰嚮宸﹀彸绠ご鍒囨崲杩囨椂闂达紝鍒檆urrentToggledTime涓哄垏鎹㈠悗鐨勬椂闂� + 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, + period: 1000, + paramDate: paramDate, + paramDateStr: paramDate.format('yyyy-MM-DD'), + start: start, + startStr: start.format('HH:mm'), + end: end, + endStr: end.format('HH:mm') + } + this.$nextTick(() => { + _this.initPlainOptions(node) + }) + }, + handleCancel() { + this.visible = false + this.stratOpen = false + this.endOpen = false + }, + checkboxOnChange(e) { + if (e.length <= 3) { + this.option = e + } else { + // this.$message.warn('鏈�澶氬彧鑳介�夋嫨3涓�') + this.$notification.warning({ + message: '娑堟伅', + description: '鏈�澶氬彧鑳介�夋嫨涓変釜' + }) + return false + } + }, + close() { + this.visible = false + this.show = false + }, + getYAxisOffset(index) { + return index * 50 + 10 + }, + initChart(param) { + if (!this.workChart) { + this.workChart = echarts.init(document.getElementById('workChart')) + } let option = { tooltip: { trigger: 'axis', @@ -237,7 +278,7 @@ } }, legend: { - data:[], + data: [] }, title: { left: 'center', @@ -252,12 +293,12 @@ saveAsImage: {} } }, - grid:{ - left:'8%', - top:'10%', - right:'2%', - bottom:'14%', - containLabel:true + grid: { + left: '8%', + top: '10%', + right: '2%', + bottom: '14%', + containLabel: true }, xAxis: { type: 'time', @@ -265,44 +306,44 @@ }, yAxis: [ { - yAxisIndex:0, - type: 'value', - offset:0, - position:'left', - boundaryGap: [0, '15%'], - axisLine:{ - show:true, - // lineStyle:{ - // color:'#000000' - // } - } - }, - { - yAxisIndex:1, + yAxisIndex: 0, type: 'value', - offset:60, - position:'left', + offset: 0, + position: 'left', boundaryGap: [0, '15%'], - axisLine:{ - show:true, + axisLine: { + show: true // lineStyle:{ // color:'#000000' // } } }, { - yAxisIndex:2, + yAxisIndex: 1, type: 'value', - offset:120, - position:'left', + offset: 60, + position: 'left', boundaryGap: [0, '15%'], - axisLine:{ - show:true, + axisLine: { + show: true // lineStyle:{ // color:'#000000' // } } }, + { + yAxisIndex: 2, + type: 'value', + offset: 120, + position: 'left', + boundaryGap: [0, '15%'], + axisLine: { + show: true + // lineStyle:{ + // color:'#000000' + // } + } + } ], dataZoom: [ { @@ -315,211 +356,236 @@ end: 20 } ], - series:[ + series: [ { - showSymbol:true, - symbolSize:20, - label:'show', - name:'', - type:'line', - data:[], - smooth:true, - symbol:'none', + showSymbol: true, + symbolSize: 20, + label: 'show', + name: '', + type: 'line', + data: [], + smooth: true, + symbol: 'none' } ] } - let _this = this - let temp = [] - for (let i = 0; i < this.plainOptions.length; i++) { - let item = this.plainOptions[i] - if (this.option.indexOf(item.value) > -1) { - temp.push(item) - } - } - getAction(this.url.workChart, param).then((res) => { - if(JSON.stringify(res.result) == '[]' || res.result == null){ - // this.$message.warning('鏃犳暟鎹紒') - this.$notification.warning({ - message:'娑堟伅', - description:'鏃犳暟鎹�!' - }); - this.spinning = false; - _this.workChart.setOption(option,true) - }else{ - this.spinning = false; - // debugger - let result = [] - let itemLine = [] - //y杞存暟缁� - var Yarr = [] - var lengenddata = []; - for (let i = 0; i < temp.length; i++) { - let item = temp[i] - itemLine = [] - for (let m = 0; m < res.result.length; m++) { - let d = [] - d.push(res.result[m].collectTime) - // debugger - d.push(res.result[m][item.englishName]) - itemLine.push(d) - } - var lll = { - name:item.label - } - lengenddata.push(lll) - var Yline ={ - name:item.label, - type:'value', - yAxisIndex:i, - boundaryGap: [0,'100%'] - } - Yarr.push(Yline); - var line ={ - name:item.label, - type:'line', - // areaStyle:{}, - smooth:true, - symbol:'circle', - symbolSize:10, - yAxisIndex:i, - - data:itemLine - } - result.push(line); - + let _this = this + let temp = [] + for (let i = 0; i < this.plainOptions.length; i++) { + let item = this.plainOptions[i] + if (this.option.indexOf(item.value) > -1) { + temp.push(item) } - // option.yAxis = Yarr; - option.series = result; - option.legend = lengenddata; - // console.log(option); - _this.workChart.setOption(option,true) - window.addEventListener('resize', function() { - _this.workChart.resize() - }) } + getAction(this.url.workChart, param).then((res) => { + if (JSON.stringify(res.result) == '[]' || res.result == null) { + // this.$message.warning('鏃犳暟鎹紒') + this.$notification.warning({ + message: '娑堟伅', + description: '鏃犳暟鎹�!' + }) + this.spinning = false + _this.workChart.setOption(option, true) + } else { + this.spinning = false + // debugger + let result = [] + let itemLine = [] + //y杞存暟缁� + var Yarr = [] + var lengenddata = [] + for (let i = 0; i < temp.length; i++) { + let item = temp[i] + itemLine = [] + for (let m = 0; m < res.result.length; m++) { + let d = [] + d.push(res.result[m].collectTime) + // debugger + d.push(res.result[m][item.englishName]) + itemLine.push(d) + } + var lll = { + name: item.label + } + lengenddata.push(lll) + var Yline = { + name: item.label, + type: 'value', + yAxisIndex: i, + boundaryGap: [0, '100%'] + } + Yarr.push(Yline) + var line = { + name: item.label, + type: 'line', + // areaStyle:{}, + smooth: true, + symbol: 'circle', + symbolSize: 10, + yAxisIndex: i, - }) + data: itemLine + } + result.push(line) + + } + // option.yAxis = Yarr; + option.series = result + option.legend = lengenddata + // console.log(option); + _this.workChart.setOption(option, true) + window.addEventListener('resize', function() { + _this.workChart.resize() + }) + } + + }) + }, + /** + * 鑾峰彇鐐瑰嚮璁惧鏃ュ織琛ㄦ牸琛屽悗浠庡厔寮熺粍浠朵紶鏉ョ殑鏃堕棿瀵硅薄 + * @param timeObj 褰撳墠琛岀殑寮�濮嬫椂闂翠笌缁撴潫鏃堕棿缁勬垚鐨勫璞� + */ + getLogListRowRecord(timeObj) { + // 鍒ゆ柇鏄惁鐐瑰嚮璁惧鏃ュ織琛ㄦ牸琛岀殑鏁版嵁锛屾鏃朵负鐐瑰嚮琛ㄦ牸鏁版嵁涓簍rue + this.isClicklogListRow = true + // 鍚堝苟鐖剁粍浠朵紶鏉ョ殑褰撳墠璁惧淇℃伅瀵硅薄涓庡厔寮熺粍浠朵紶鏉ョ殑褰撳墠琛岀殑鏃堕棿瀵硅薄 + const newQueryParams = Object.assign(this.equipment, timeObj) + this.add(newQueryParams) + this.title = '宸ヤ綔鏇茬嚎' + } } } -} </script> <style scoped lang="less"> -.full-modal { - .ant-modal { - max-width: 100%; - top: 0; - padding-bottom: 0; - margin: 0; + .full-modal { + .ant-modal { + max-width: 100%; + top: 0; + padding-bottom: 0; + margin: 0; + } + .ant-modal-content { + display: flex; + flex-direction: column; + height: calc(100vh); + } + .ant-modal-body { + flex: 1; + } } - .ant-modal-content { + + /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)));*/ + /*background: -webkit-linear-gradient(left, rgba(0, 0, 0, 0.66) 0%, rgba(0, 0, 0, 0.4) 100%);*/ + /*background: -o-linear-gradient(left, rgba(0, 0, 0, 0.66) 0%, rgba(0, 0, 0, 0.4) 100%);*/ + /*background: -ms-linear-gradient(left, rgba(0, 0, 0, 0.66) 0%, rgba(0, 0, 0, 0.4) 100%);*/ + /*background: linear-gradient(to right, rgba(0, 0, 0, 0.66) 0%, rgba(0, 0, 0, 0.4) 100%);*/ + /*background-color: #000;*/ + /*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%; + display: flex; + justify-content: center; + align-items: center; + flex-direction: column; + } + + /deep/ .ant-checkbox-group { display: flex; flex-direction: column; - height: calc(100vh); } - .ant-modal-body { - flex: 1; + + /deep/ .ant-checkbox-group .ant-checkbox-wrapper { + padding: 10px; } -} -/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)));*/ - /*background: -webkit-linear-gradient(left, rgba(0, 0, 0, 0.66) 0%, rgba(0, 0, 0, 0.4) 100%);*/ - /*background: -o-linear-gradient(left, rgba(0, 0, 0, 0.66) 0%, rgba(0, 0, 0, 0.4) 100%);*/ - /*background: -ms-linear-gradient(left, rgba(0, 0, 0, 0.66) 0%, rgba(0, 0, 0, 0.4) 100%);*/ - /*background: linear-gradient(to right, rgba(0, 0, 0, 0.66) 0%, rgba(0, 0, 0, 0.4) 100%);*/ - /*background-color: #000;*/ - /*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%; - display: flex; - justify-content: center; - align-items: center; - flex-direction: column; -} -/deep/ .ant-checkbox-group{ - display: flex; - flex-direction: column; -} -/deep/ .ant-checkbox-group .ant-checkbox-wrapper{ - padding: 10px; -} + .con_btn { + display: flex; + align-items: center; + } -.con_btn{ - 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; -} + .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; - margin-left: 3px; -} + .ant-btn { + padding: 0 10px; + margin-left: 3px; + } -.ant-form-item-control { - line-height: 0px; -} + .ant-form-item-control { + line-height: 0px; + } -/** 涓昏〃鍗曡闂磋窛 */ -.ant-form .ant-form-item { - margin-bottom: 10px; -} + /** 涓昏〃鍗曡闂磋窛 */ + .ant-form .ant-form-item { + margin-bottom: 10px; + } -/** Tab椤甸潰琛岄棿璺� */ -.ant-tabs-content .ant-form-item { - margin-bottom: 0px; -} + /** Tab椤甸潰琛岄棿璺� */ + .ant-tabs-content .ant-form-item { + margin-bottom: 0px; + } </style> diff --git a/src/views/mdc/base/modules/deviceRepair/DeviceRepairList.vue b/src/views/mdc/base/modules/deviceRepair/DeviceRepairList.vue index c993065..5346318 100644 --- a/src/views/mdc/base/modules/deviceRepair/DeviceRepairList.vue +++ b/src/views/mdc/base/modules/deviceRepair/DeviceRepairList.vue @@ -1,5 +1,5 @@ <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"> @@ -68,7 +68,7 @@ <!--<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> diff --git a/src/views/mdc/base/modules/efficiencyPOReport/EfficiencyPOList.vue b/src/views/mdc/base/modules/efficiencyPOReport/EfficiencyPOList.vue index ceb9705..d5c0b4a 100644 --- a/src/views/mdc/base/modules/efficiencyPOReport/EfficiencyPOList.vue +++ b/src/views/mdc/base/modules/efficiencyPOReport/EfficiencyPOList.vue @@ -1,6 +1,6 @@ <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"> @@ -28,7 +28,7 @@ </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> @@ -101,7 +101,7 @@ </table> </div> </div> - </a-card> + </div> </div> </template> diff --git a/src/views/mdc/base/modules/efficiencyReport/EfficiencyList.vue b/src/views/mdc/base/modules/efficiencyReport/EfficiencyList.vue index e679650..eeda3d2 100644 --- a/src/views/mdc/base/modules/efficiencyReport/EfficiencyList.vue +++ b/src/views/mdc/base/modules/efficiencyReport/EfficiencyList.vue @@ -1,6 +1,6 @@ <template> <div class="efficiency_list" style="width: 100%"> - <a-card :bordered="false"> + <div :bordered="false"> <!-- 鏌ヨ鍖哄煙 --> <div> <div class="table-page-search-wrapper"> @@ -29,7 +29,7 @@ </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> @@ -103,7 +103,7 @@ </table> </div> </div> - </a-card> + </div> </div> </template> diff --git a/src/views/mdc/base/modules/efficiencyShiftReport/EfficiencyShiftList.vue b/src/views/mdc/base/modules/efficiencyShiftReport/EfficiencyShiftList.vue index a5a6391..b3e08fb 100644 --- a/src/views/mdc/base/modules/efficiencyShiftReport/EfficiencyShiftList.vue +++ b/src/views/mdc/base/modules/efficiencyShiftReport/EfficiencyShiftList.vue @@ -1,6 +1,6 @@ <template> <div style="width: 100%;"> - <a-card :bordered="false"> + <div :bordered="false"> <!-- 鏌ヨ鍖哄煙 --> <div class="seach-content"> <div class="table-page-search-wrapper"> @@ -49,7 +49,7 @@ </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> @@ -143,7 +143,7 @@ </table> </div> </div> - </a-card> + </div> </div> </template> diff --git a/src/views/mdc/base/modules/equipmentAvailCompare/equipmentAvailCompareMain.vue b/src/views/mdc/base/modules/equipmentAvailCompare/equipmentAvailCompareMain.vue index faba4d8..9f83208 100644 --- a/src/views/mdc/base/modules/equipmentAvailCompare/equipmentAvailCompareMain.vue +++ b/src/views/mdc/base/modules/equipmentAvailCompare/equipmentAvailCompareMain.vue @@ -1,6 +1,6 @@ <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"> @@ -46,7 +46,7 @@ </div> <!-- table鍖哄煙-end --> </div> - </a-card> + </div> </a-spin> </template> diff --git a/src/views/mdc/base/modules/equipmentDayAvail/equipmentDayAvailMain.vue b/src/views/mdc/base/modules/equipmentDayAvail/equipmentDayAvailMain.vue index fa95c5d..e1a41c1 100644 --- a/src/views/mdc/base/modules/equipmentDayAvail/equipmentDayAvailMain.vue +++ b/src/views/mdc/base/modules/equipmentDayAvail/equipmentDayAvailMain.vue @@ -1,5 +1,5 @@ <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"> @@ -57,7 +57,7 @@ </div> <!-- table鍖哄煙-end --> </div> - </a-card> + </div> </template> <script> diff --git a/src/views/mdc/base/modules/mdcPassRate/mdcPassRateList.vue b/src/views/mdc/base/modules/mdcPassRate/mdcPassRateList.vue index 3b6c3a4..30e763b 100644 --- a/src/views/mdc/base/modules/mdcPassRate/mdcPassRateList.vue +++ b/src/views/mdc/base/modules/mdcPassRate/mdcPassRateList.vue @@ -1,5 +1,5 @@ <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"> @@ -85,7 +85,7 @@ <!--<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> diff --git a/src/views/mdc/base/modules/mdcProcessQuantity/mdcProcessQuantityList.vue b/src/views/mdc/base/modules/mdcProcessQuantity/mdcProcessQuantityList.vue index c5f34cc..35fa3d3 100644 --- a/src/views/mdc/base/modules/mdcProcessQuantity/mdcProcessQuantityList.vue +++ b/src/views/mdc/base/modules/mdcProcessQuantity/mdcProcessQuantityList.vue @@ -1,5 +1,5 @@ <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"> @@ -81,7 +81,7 @@ <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> diff --git a/src/views/mdc/base/modules/mdcStandardProcessDuration/MdcStandardProcessDurationList.vue b/src/views/mdc/base/modules/mdcStandardProcessDuration/MdcStandardProcessDurationList.vue index 5cb2f9a..f0ed5b0 100644 --- a/src/views/mdc/base/modules/mdcStandardProcessDuration/MdcStandardProcessDurationList.vue +++ b/src/views/mdc/base/modules/mdcStandardProcessDuration/MdcStandardProcessDurationList.vue @@ -1,5 +1,5 @@ <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"> @@ -81,7 +81,7 @@ <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> diff --git a/src/views/mdc/base/modules/openRateFractionAnalysis/openRateFractionAnalysisMain.vue b/src/views/mdc/base/modules/openRateFractionAnalysis/openRateFractionAnalysisMain.vue index 42a5bb9..845ff29 100644 --- a/src/views/mdc/base/modules/openRateFractionAnalysis/openRateFractionAnalysisMain.vue +++ b/src/views/mdc/base/modules/openRateFractionAnalysis/openRateFractionAnalysisMain.vue @@ -1,6 +1,6 @@ <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"> @@ -64,7 +64,7 @@ </div> <div id="openRateTrendChart" style="width: 100%;height: 60%"></div> </div> - </a-card> + </div> </div> </template> diff --git a/src/views/mdc/base/modules/openRateTrendAnalysis/openRateTrendAnalysisMain.vue b/src/views/mdc/base/modules/openRateTrendAnalysis/openRateTrendAnalysisMain.vue index 952a59b..87af8d1 100644 --- a/src/views/mdc/base/modules/openRateTrendAnalysis/openRateTrendAnalysisMain.vue +++ b/src/views/mdc/base/modules/openRateTrendAnalysis/openRateTrendAnalysisMain.vue @@ -1,6 +1,6 @@ <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"> @@ -57,7 +57,7 @@ </div> <div id="openRateTrendChart" style="width: 100%;height: 60%"></div> </div> - </a-card> + </div> </div> </template> -- Gitblit v1.9.3