From c29371e319fb8965cdcb709c87a9c885b94b835c Mon Sep 17 00:00:00 2001 From: zhangjunwen Date: Thu, 10 Oct 2024 10:13:45 +0800 Subject: [PATCH] =?UTF-8?q?=E7=9B=91=E6=8E=A7=E6=95=B0=E6=8D=AE=E7=AE=A1?= =?UTF-8?q?=E7=90=86=E6=B7=BB=E5=8A=A0=E8=AE=BE=E5=A4=87=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E9=A1=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../admin/query/DataQueryController.java | 2 +- .../admin/query/vo/CurrentDataRespVO.java | 8 +- .../admin/query/vo/PressDataRespVO.java | 12 +- .../admin/query/vo/ProcessDataRespVO.java | 16 +- .../admin/query/vo/TempDataRespVO.java | 36 ++- .../admin/query/vo/VibrDataRespVO.java | 55 +++- .../service/equip/EquipInfoServiceImpl.java | 7 +- .../src/layout/components/Message/index.vue | 99 +++++-- .../views/system/data/monitordata/index.vue | 257 +++++++++++++++--- 9 files changed, 390 insertions(+), 102 deletions(-) diff --git a/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/DataQueryController.java b/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/DataQueryController.java index 6865416..6a808e7 100644 --- a/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/DataQueryController.java +++ b/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/DataQueryController.java @@ -149,7 +149,7 @@ public class DataQueryController { HttpServletResponse response) throws IOException, ParseException { List list = (List)dataQueryService.selectDataListByPages(equipId,tableName,startTime,endTime,null,null).get("list"); // 导出 Excel - ExcelUtils.write(response, "机床振动参数报警记录.xls", "振动数据", VibrDataRespVO.class, + ExcelUtils.write(response, "机床加速度参数报警记录.xls", "加速度数据", VibrDataRespVO.class, BeanUtils.toBean(list, VibrDataRespVO.class)); } diff --git a/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/CurrentDataRespVO.java b/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/CurrentDataRespVO.java index 6bf9d50..815524b 100644 --- a/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/CurrentDataRespVO.java +++ b/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/CurrentDataRespVO.java @@ -14,10 +14,10 @@ public class CurrentDataRespVO { @ExcelProperty("时间") private String time; - @ExcelProperty("x轴推屑电流") - private String x_push_temp; + @ExcelProperty("排屑1电流(A)") + private String chip_removal_1; - @ExcelProperty("y轴推屑电流") - private String y_push_temp; + @ExcelProperty("排屑2电流(A)") + private String chip_removal_2; } diff --git a/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/PressDataRespVO.java b/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/PressDataRespVO.java index d4ff859..b00b21a 100644 --- a/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/PressDataRespVO.java +++ b/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/PressDataRespVO.java @@ -15,12 +15,12 @@ public class PressDataRespVO { @ExcelProperty("时间") private String time; - @ExcelProperty("x轴润滑压力") - private String x_lube_press; + @ExcelProperty("液压1(bar)") + private String hy_1; - @ExcelProperty("y轴润滑压力") - private String y_lube_press; + @ExcelProperty("液压2(bar)") + private String hy_2; - @ExcelProperty("z轴润滑压力") - private String z_lube_press; + @ExcelProperty("液压3(bar)") + private String hy_3; } diff --git a/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/ProcessDataRespVO.java b/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/ProcessDataRespVO.java index 39e87ab..3932ba7 100644 --- a/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/ProcessDataRespVO.java +++ b/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/ProcessDataRespVO.java @@ -14,15 +14,15 @@ public class ProcessDataRespVO { @ExcelProperty("时间") private String time; - @ExcelProperty("加工总件数") - private String work_total; + @ExcelProperty("加工总件数(件)") + private String total_process; - @ExcelProperty("加工时长") + @ExcelProperty("加工件数(件)") + private String process_num; + + @ExcelProperty("加工时长(分钟)") private String work_time; - @ExcelProperty("通电时间") - private String on_time; - - @ExcelProperty("加工件数") - private String work_items; + @ExcelProperty("通电时间(分钟)") + private String power_time; } diff --git a/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/TempDataRespVO.java b/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/TempDataRespVO.java index 5a46d0f..f81c863 100644 --- a/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/TempDataRespVO.java +++ b/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/TempDataRespVO.java @@ -14,12 +14,36 @@ public class TempDataRespVO { @ExcelProperty("时间") private String time; - @ExcelProperty("x轴轴承温度") - private String x_bear_temp; + @ExcelProperty("X+温度(℃)") + private String xp_temp; - @ExcelProperty("y轴轴承温度") - private String y_bear_temp; + @ExcelProperty("X0温度(℃)") + private String x0_temp; - @ExcelProperty("x轴轴承温度") - private String z_bear_temp; + @ExcelProperty("X-温度(℃)") + private String xn_temp; + + @ExcelProperty("Y+温度(℃)") + private String yp_temp; + + @ExcelProperty("Y0温度(℃)") + private String y0_temp; + + @ExcelProperty("Y-温度(℃)") + private String yn_temp; + + @ExcelProperty("Z+温度(℃)") + private String zp_temp; + + @ExcelProperty("Z0温度(℃)") + private String z0_temp; + + @ExcelProperty("Z-温度(℃)") + private String zn_temp; + + @ExcelProperty("排屑1温度(℃)") + private String cr1_temp; + + @ExcelProperty("排屑2温度(℃)") + private String cr2_temp; } diff --git a/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/VibrDataRespVO.java b/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/VibrDataRespVO.java index ab78a6b..ed36607 100644 --- a/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/VibrDataRespVO.java +++ b/imt-server/imt-module-data/imt-module-data-biz/src/main/java/com/inspur/module/data/controller/admin/query/vo/VibrDataRespVO.java @@ -14,6 +14,57 @@ public class VibrDataRespVO { @ExcelProperty("时间") private String time; - @ExcelProperty("y轴熵值") - private String x_entropy; + @ExcelProperty("X加速度RMS") + private String x_aclr_rms; + + @ExcelProperty("Y加速度RMS") + private String y_aclr_rms; + + @ExcelProperty("Z加速度RMS") + private String z_aclr_rms; + + @ExcelProperty("X速度RMS") + private String x_speed_rms; + + @ExcelProperty("Y速度RMS") + private String y_speed_rms; + + @ExcelProperty("Z速度RMS") + private String z_speed_rms; + + @ExcelProperty("X位移RMS") + private String x_dis_rms; + + @ExcelProperty("Y位移RMS") + private String y_dis_rms; + + @ExcelProperty("Z位移RMS") + private String z_dis_rms; + + @ExcelProperty("X加速度峰值") + private String x_aclr_peak; + + @ExcelProperty("Y加速度峰值") + private String y_aclr_peak; + + @ExcelProperty("Z加速度峰值") + private String z_aclr_peak; + + @ExcelProperty("X速度峰值") + private String x_speed_peak; + + @ExcelProperty("Y速度峰值") + private String y_speed_peak; + + @ExcelProperty("Z速度峰值") + private String z_speed_peak; + + @ExcelProperty("X位移峰值") + private String x_dis_peak; + + @ExcelProperty("Y位移峰值") + private String y_dis_peak; + + @ExcelProperty("Z位移峰值") + private String z_dis_peak; } diff --git a/imt-server/imt-module-system/imt-module-system-biz/src/main/java/com/inspur/module/system/service/equip/EquipInfoServiceImpl.java b/imt-server/imt-module-system/imt-module-system-biz/src/main/java/com/inspur/module/system/service/equip/EquipInfoServiceImpl.java index 30ee677..d7c58fc 100644 --- a/imt-server/imt-module-system/imt-module-system-biz/src/main/java/com/inspur/module/system/service/equip/EquipInfoServiceImpl.java +++ b/imt-server/imt-module-system/imt-module-system-biz/src/main/java/com/inspur/module/system/service/equip/EquipInfoServiceImpl.java @@ -2,6 +2,7 @@ package com.inspur.module.system.service.equip; import cn.hutool.core.collection.CollUtil; import cn.hutool.core.util.StrUtil; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.inspur.framework.common.pojo.PageResult; import com.inspur.framework.tenant.core.aop.TenantIgnore; import com.inspur.module.system.controller.baseData.vo.CustomerInfoSelectionVO; @@ -97,7 +98,9 @@ public class EquipInfoServiceImpl implements EquipInfoService { List list = new ArrayList<>(); if (CollUtil.isNotEmpty(customerList)){ //所有机床信息 - List equipInfoList = equipInfoMapper.selectList(); + QueryWrapper queryWrapper = new QueryWrapper<>(); + queryWrapper.orderBy(true,true,"create_time"); + List equipInfoList = equipInfoMapper.selectList(queryWrapper); Map> equipInfoMap = equipInfoList.stream().collect(Collectors.groupingBy(EquipInfoDO::getCustomerId)); customerList.forEach(item -> { EquipCascaderVO vo = new EquipCascaderVO(); @@ -109,7 +112,7 @@ public class EquipInfoServiceImpl implements EquipInfoService { equipInfoDOList.forEach(equip -> { EquipCascaderVO equipCascaderVO = new EquipCascaderVO(); equipCascaderVO.setId(equip.getEquipId()); - equipCascaderVO.setName(equip.getEquipNo()); + equipCascaderVO.setName(equip.getEquipName()); children.add(equipCascaderVO); }); if (CollUtil.isNotEmpty(children)){ diff --git a/imt-ui/src/layout/components/Message/index.vue b/imt-ui/src/layout/components/Message/index.vue index c27e8ee..7b30246 100644 --- a/imt-ui/src/layout/components/Message/index.vue +++ b/imt-ui/src/layout/components/Message/index.vue @@ -1,40 +1,81 @@