ZengTao
2025-05-26 d3e76a8afe548f5f9e51de37f26b3cb8aa7374a1
大屏样式修改
22个文件已修改
246 ■■■■ 已修改文件
UI-Project/src/lang/zh.js 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
UI-Project/src/views/largescreendisplay/screendisplay.vue 49 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
UI-Project/src/views/largescreendisplay/timeaxis.vue 62 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheGlassModule/pom.xml 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/job/PushMessageToIndex.java 25 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/opctask/controller/EdgStorageDeviceTaskHistoryController.java 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/opctask/mapper/EdgStorageDeviceTaskHistoryMapper.java 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/opctask/service/EdgStorageDeviceTaskHistoryService.java 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/opctask/service/impl/EdgStorageDeviceTaskHistoryServiceImpl.java 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheGlassModule/src/main/resources/mapper/EdgStorageDeviceTaskHistoryMapper.xml 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/bigstoragecagetask/controller/BigStorageCageHistoryTaskController.java 13 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/bigstoragecagetask/mapper/BigStorageCageHistoryTaskMapper.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/bigstoragecagetask/service/BigStorageCageHistoryTaskService.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/bigstoragecagetask/service/impl/BigStorageCageHistoryTaskServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/job/OPCPlcSlicecage.java 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/resources/mapper/BigStorageCageHistoryTaskMapper.xml 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/hollowGlassModule/src/main/java/com/mes/hollowtask/controller/HollowBigStorageCageHistoryTaskController.java 13 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/hollowGlassModule/src/main/java/com/mes/hollowtask/mapper/HollowBigStorageCageHistoryTaskMapper.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/hollowGlassModule/src/main/java/com/mes/hollowtask/service/HollowBigStorageCageHistoryTaskService.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/hollowGlassModule/src/main/java/com/mes/hollowtask/service/impl/HollowBigStorageCageHistoryTaskServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/hollowGlassModule/src/main/java/com/mes/job/PushMessageToIndex.java 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
hangzhoumesParent/moduleService/hollowGlassModule/src/main/resources/mapper/HollowBigStorageCageHistoryTaskMapper.xml 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
UI-Project/src/lang/zh.js
@@ -521,7 +521,7 @@
        hollowState:'中空当天运行情况',
        switch:'切换',
        running:'运行中',
        stopping:'停止中',
        stopping:'停止',
        diffMinutes:'分钟',
        loadstart:'切割开始时间',
        loadend:'切割结束时间',
UI-Project/src/views/largescreendisplay/screendisplay.vue
@@ -38,17 +38,17 @@
let myChartHollow = null;
const socketUrl1 = `ws://${WebSocketHost}:${host}/api/cacheGlass/api/talk/largenScreen`;
const handleMessage1 = (data) => {
  edgOneTasks.value = data.edgOneTasks[0];
  edgTwoTasks.value = data.edgTwoTasks[0];
  edgOneTasks.value = data.edgOneCount[0];
  edgTwoTasks.value = data.edgOneCount[0];
  engineeringOne.value = data.engineeringOne[0];
  engineeringTwo.value = data.engineeringTwo[0];
  if (numBoxes.value != edgOneTasks.value.length) {
    numBoxes.value = edgOneTasks.value.length;
  if (numBoxes.value != edgOneTasks.value) {
    numBoxes.value = edgOneTasks.value;
    initBoxes(boxes, numBoxes, 'firstup');
  }
  if (numBoxes2.value != edgTwoTasks.value.length) {
    numBoxes2.value = edgTwoTasks.value.length;
  if (numBoxes2.value != edgTwoTasks.value) {
    numBoxes2.value = edgTwoTasks.value;
    initBoxes(boxes2, numBoxes2, 'firstup');
  }
  timeAxisCreate(t('large.cuttingState'), chartLoad.value, myChartLoad, tableDataTime(false, data.loadRunTimes[0]));
@@ -106,15 +106,20 @@
  const tableData = [];
  if (tableDatax.length > 0) {
    tableDatax.forEach((item, index) => {
      tableData.push({
        firstTimestamp: index == 0 ? item.startTimestamp : tableDatax[index - 1].secondTimestamp,
        secondTimestamp: index == tableDatax.length - 1 ? item.endTimestamp : item.firstTimestamp,
        diffMinutes: item.diffMinutes,
        startTimestamp: item.startTimestamp,
        endTimestamp: item.endTimestamp,
        state: 1
      });
      if (result) {
      const time1 = new Date(index == 0 ? item.startTimestamp : tableDatax[index - 1].secondTimestamp);
      const time2 = new Date(index == tableDatax.length - 1 ? item.endTimestamp : item.firstTimestamp);
      const diffInSeconds = Math.abs(time2 - time1) / 1000;
      if (diffInSeconds > 60) {
        tableData.push({
          firstTimestamp: index == 0 ? item.startTimestamp : tableDatax[index - 1].secondTimestamp,
          secondTimestamp: index == tableDatax.length - 1 ? item.endTimestamp : item.firstTimestamp,
          diffMinutes: item.diffMinutes,
          startTimestamp: item.startTimestamp,
          endTimestamp: item.endTimestamp,
          state: 1
        });
        if (result) {
        tableData.push({
          firstTimestamp: item.firstTimestamp,
          secondTimestamp: item.secondTimestamp,
@@ -124,6 +129,14 @@
          state: 2
        });
      }
        // console.log("间隔超过60秒", diffInSeconds, time1, time2);
      } else {
        if(index>0){
        // console.log(tableData,index);
        }
        // console.log("间隔不超过60秒", diffInSeconds, time1, time2);
      }
    });
  }
@@ -270,7 +283,7 @@
    ]
  };
  mychart.setOption(optionOne);
  mychart.setOption(optionOne,true);
};
let socket4 = null;
@@ -347,7 +360,7 @@
    ]
  };
  myChart.setOption(option);
  myChart.setOption(option,true);
  const chartDom2 = chartRef2.value;
@@ -393,7 +406,7 @@
    ]
  };
  myChart2.setOption(option2);
  myChart2.setOption(option2,true);
};
// 将原始数据转换为 ECharts 图表所需格式
let categories = ref([]); // 获取日期作为 x 轴
UI-Project/src/views/largescreendisplay/timeaxis.vue
@@ -60,7 +60,14 @@
const historical = async () => {
  try {
    let startTime = window.localStorage.getItem('startTime')
    const response = await request.get("/cacheGlass/edgStorageDeviceTaskHistory/queryRunTimes?days=" + timeRange.value[1])
    let response;
    if (key == "1" || key == "2") {
      response = await request.get("/cacheGlass/edgStorageDeviceTaskHistory/queryRunTimes?days=" + timeRange.value[1])
    } else if (key == "3") {
      response = await request.get("/cacheVerticalGlass/bigStorageCageHistoryTask/queryRunTimes?days=" + timeRange.value[1])
    } else {
      response = await request.get("/hollowGlass/hollowBigStorageCageHistoryTask/queryRunTimes?days=" + timeRange.value[1])
    }
    if (response.code == 200) {
      ElMessage.success(response.message);
      // const formattedData = response.data.records.map(record => ({
@@ -90,14 +97,24 @@
  const tableData = [];
  if (tableDatax.value.length > 0) {
    tableDatax.value.forEach((item, index) => {
      tableData.push({
        firstTimestamp: index == 0 ? item.startTimestamp : tableDatax.value[index - 1].secondTimestamp,
        secondTimestamp: index == tableDatax.length - 1 ? item.endTimestamp : item.firstTimestamp,
        diffMinutes: item.diffMinutes,
        startTimestamp: item.startTimestamp,
        endTimestamp: item.endTimestamp,
        state: 1
      });
      const time1 = new Date(index == 0 ? item.startTimestamp : tableDatax.value[index - 1].secondTimestamp);
      const time2 = new Date(index == tableDatax.length - 1 ? item.endTimestamp : item.firstTimestamp);
      const diffInSeconds = Math.abs(time2 - time1) / 1000;
      if (diffInSeconds > 60) {
        tableData.push({
          firstTimestamp: index == 0 ? item.startTimestamp : tableDatax.value[index - 1].secondTimestamp,
          secondTimestamp: index == tableDatax.length - 1 ? item.endTimestamp : item.firstTimestamp,
          diffMinutes: item.diffMinutes,
          startTimestamp: item.startTimestamp,
          endTimestamp: item.endTimestamp,
          state: 1
        });
        console.log("间隔超过60秒", diffInSeconds, time1, time2);
      } else {
        console.log("间隔不超过60秒", diffInSeconds, time1, time2);
      }
      if (result) {
        tableData.push({
          firstTimestamp: item.firstTimestamp,
@@ -130,7 +147,14 @@
    }
    let page = window.localStorage.getItem('pagenumber')
    let startTime = window.localStorage.getItem('startTime')
    const response = await request.get("/cacheGlass/edgStorageDeviceTaskHistory/queryRunTimes?days=" + timeRange.value[1])
    let response;
    if (key == "1" || key == "2") {
      response = await request.get("/cacheGlass/edgStorageDeviceTaskHistory/queryRunTimes?days=" + timeRange.value[1])
    } else if (key == "3") {
      response = await request.get("/cacheVerticalGlass/bigStorageCageHistoryTask/queryRunTimes?days=" + timeRange.value[1])
    } else {
      response = await request.get("/hollowGlass/hollowBigStorageCageHistoryTask/queryRunTimes?days=" + timeRange.value[1])
    }
    if (response.code == 200) {
      ElMessage.success(response.message);
      // const formattedData = response.data.records.map(record => ({
@@ -167,7 +191,14 @@
    }
    let startTime = window.localStorage.getItem('startTime')
    let page = window.localStorage.getItem('pagenumber')
    const response = await request.get("/cacheGlass/edgStorageDeviceTaskHistory/queryRunTimes?days=" + timeRange.value[1])
    let response;
    if (key == "1" || key == "2") {
      response = await request.get("/cacheGlass/edgStorageDeviceTaskHistory/queryRunTimes?days=" + timeRange.value[1])
    } else if (key == "3") {
      response = await request.get("/cacheVerticalGlass/bigStorageCageHistoryTask/queryRunTimes?days=" + timeRange.value[1])
    } else {
      response = await request.get("/hollowGlass/hollowBigStorageCageHistoryTask/queryRunTimes?days=" + timeRange.value[1])
    }
    if (response.code == 200) {
      currentPage2.value = 1
      ElMessage.success(response.message);
@@ -291,6 +322,10 @@
let myChart = null;
const chart = ref(null)
const timeAxisCreate = (title, chartDom, mychart, RunTimes) => {
  if (mychart) {
    mychart.clear();
    // 如果需要,可以重新初始化图表
  }
  if (!chartDom) {
    console.error('图表容器未找到');
    return;
@@ -335,8 +370,7 @@
    },
    z: 1
  }));
  console.log("segments", RunTimes.length, segments);
  const optionOne = {
    title: {
      text: title,
@@ -430,7 +464,7 @@
    ]
  };
  mychart.setOption(optionOne);
  mychart.setOption(optionOne, true);
};
</script>
hangzhoumesParent/moduleService/CacheGlassModule/pom.xml
@@ -34,5 +34,28 @@
        <java.run.main.class>com.mes.CacheGlassModuleApplication</java.run.main.class>
    </properties>
    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <version>3.2.0</version>
                <configuration>
                    <archive>
                        <manifest>
                            <addClasspath>true</addClasspath>
                            <classpathPrefix>lib/</classpathPrefix>
                            <mainClass>com.mes.CacheGlassModuleApplication</mainClass>
                        </manifest>
                        <manifestEntries>
                            <Class-Path>resources/</Class-Path>
                        </manifestEntries>
                    </archive>
                    <outputDirectory>${project.build.directory}</outputDirectory>
                </configuration>
            </plugin>
        </plugins>
    </build>
</project>
hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/job/PushMessageToIndex.java
@@ -24,8 +24,11 @@
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
import java.text.SimpleDateFormat;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.time.ZoneId;
import java.time.format.DateTimeFormatter;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
@@ -182,21 +185,27 @@
        ArrayList<WebSocketServer> sendwServer = WebSocketServer.sessionMap.get("largenScreen");
        if (sendwServer != null) {
            Date startOfToday = new Date(LocalDate.now().atStartOfDay(ZoneId.systemDefault()).toInstant().toEpochMilli());
            List<EdgGlassTaskInfo> edgOneTasks = edgGlassTaskInfoService.list(
            SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
            String formatted = sdf.format(startOfToday);
            LocalDate date = LocalDate.parse(formatted); // formatted = "2025-05-23"
            LocalDateTime start = date.atStartOfDay(); // 2025-05-23 00:00:00
            LocalDateTime end = date.plusDays(1).atStartOfDay();
            int edgOneCount = edgGlassTaskInfoService.count(
                    new LambdaQueryWrapper<EdgGlassTaskInfo>()
                            .lt(EdgGlassTaskInfo::getState, 2)
                            .eq(EdgGlassTaskInfo::getLine, 1)
                            .ge(EdgGlassTaskInfo::getCreateTime, startOfToday)
                            .between(EdgGlassTaskInfo::getCreateTime, start, end)
            );
            List<EdgGlassTaskInfo> edgTwoTasks = edgGlassTaskInfoService.list(
            edgOneCount = edgOneCount >= 6 ? 6 : edgOneCount;
            int edgTwoCount = edgGlassTaskInfoService.count(
                    new LambdaQueryWrapper<EdgGlassTaskInfo>()
                            .lt(EdgGlassTaskInfo::getState, 2)
                            .eq(EdgGlassTaskInfo::getLine, 2)
                            .ge(EdgGlassTaskInfo::getCreateTime, startOfToday)
                            .between(EdgGlassTaskInfo::getCreateTime, start, end)
            );
            jsonObject.append("edgOneTasks", edgOneTasks);
            jsonObject.append("edgTwoTasks", edgTwoTasks);
            edgTwoCount = edgTwoCount >= 6 ? 6 : edgTwoCount;
            jsonObject.append("edgOneCount", edgOneCount);
            jsonObject.append("edgTwoCount", edgTwoCount);
            List<Engineering> engineeringOne = engineeringService.list(
                    new LambdaQueryWrapper<Engineering>()
                            .eq(Engineering::getStationCell, 5)
@@ -211,7 +220,7 @@
            jsonObject.append("engineeringTwo", engineeringTow);
            List<PieChartVO> pieChartVOS = edgStorageCageDetailsService.queryPieChart();
            jsonObject.append("pieChartVOS", pieChartVOS);
            List<RunTime> loadRunTimes = edgStorageDeviceTaskHistoryService.queryRunTimes();
            List<RunTime> loadRunTimes = edgStorageDeviceTaskHistoryService.queryRunTimes(LocalDate.now().format(DateTimeFormatter.ofPattern("yyyy-MM-dd")));
            jsonObject.append("loadRunTimes", loadRunTimes);
            for (WebSocketServer webserver : sendwServer) {
                if (webserver != null) {
hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/opctask/controller/EdgStorageDeviceTaskHistoryController.java
@@ -3,6 +3,7 @@
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.mes.largenscreen.entity.DailyProductionVO;
import com.mes.largenscreen.entity.RunTime;
import com.mes.opctask.entity.EdgStorageDeviceTaskHistory;
import com.mes.opctask.entity.request.TaskHistoryRequest;
import com.mes.opctask.service.EdgStorageDeviceTaskHistoryService;
@@ -10,12 +11,11 @@
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource;
import java.util.Date;
import java.util.List;
/**
 * (EdgStorageDeviceTaskHistory)表控制层
@@ -45,5 +45,11 @@
        return Result.success(edgStorageDeviceTaskHistoryService.queryEdgDailyProduction(request));
    }
    @ApiOperation(value = "查询生产线运行情况", notes = "查询生产线运行情况")
    @GetMapping("/queryRunTimes")
    public Result<List<RunTime>> queryRunTimes(String days) {
        return Result.success(edgStorageDeviceTaskHistoryService.queryRunTimes(days));
    }
}
hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/opctask/mapper/EdgStorageDeviceTaskHistoryMapper.java
@@ -6,6 +6,7 @@
import com.mes.opctask.entity.EdgStorageDeviceTaskHistory;
import org.apache.ibatis.annotations.Param;
import java.util.Date;
import java.util.List;
/**
@@ -18,6 +19,6 @@
    DailyProductionVO queryEdgDailyProduction(@Param("beginDate") String beginDate, @Param("endDate") String endDate, @Param("deviceId") Integer deviceId);
    List<RunTime> queryRunTimes();
    List<RunTime> queryRunTimes(@Param("days") String days);
}
hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/opctask/service/EdgStorageDeviceTaskHistoryService.java
@@ -7,6 +7,7 @@
import com.mes.opctask.entity.EdgStorageDeviceTaskHistory;
import com.mes.opctask.entity.request.TaskHistoryRequest;
import java.util.Date;
import java.util.List;
/**
@@ -21,6 +22,6 @@
    DailyProductionVO queryEdgDailyProduction(TaskHistoryRequest request);
    List<RunTime> queryRunTimes();
    List<RunTime> queryRunTimes(String days);
}
hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/opctask/service/impl/EdgStorageDeviceTaskHistoryServiceImpl.java
@@ -13,6 +13,7 @@
import org.springframework.stereotype.Service;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.List;
/**
@@ -53,8 +54,8 @@
    }
    @Override
    public List<RunTime> queryRunTimes(){
        return baseMapper.queryRunTimes();
    public List<RunTime> queryRunTimes(String days){
        return baseMapper.queryRunTimes(days);
    }
}
hangzhoumesParent/moduleService/CacheGlassModule/src/main/resources/mapper/EdgStorageDeviceTaskHistoryMapper.xml
@@ -38,7 +38,7 @@
    <select id="queryRunTimes" resultType="com.mes.largenscreen.entity.RunTime">
        with edg_storage_cage_history_task_temp as (
            select distinct create_time from edg_storage_device_task_history  where task_type in (1,3) and
                create_time  BETWEEN CURDATE() AND DATE_ADD(CURDATE(), INTERVAL 1 DAY)
                create_time LIKE '%${days}%'
        )
        SELECT
            t1.create_time AS first_timestamp,
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/bigstoragecagetask/controller/BigStorageCageHistoryTaskController.java
@@ -5,16 +5,15 @@
import com.mes.bigstoragecagetask.entity.request.BigStorageCageHistoryRequest;
import com.mes.bigstoragecagetask.service.BigStorageCageHistoryTaskService;
import com.mes.largenscreen.entity.DailyProductionVO;
import com.mes.largenscreen.entity.RunTime;
import com.mes.utils.Result;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource;
import java.util.List;
/**
 * @Author : zhoush
@@ -40,4 +39,10 @@
    public Result<DailyProductionVO> queryBigDailyProduction(@RequestBody BigStorageCageHistoryRequest request) {
        return Result.success(bigStorageCageHistoryTaskService.queryBigDailyProduction(request));
    }
    @ApiOperation(value = "查询生产线运行情况", notes = "查询生产线运行情况")
    @GetMapping("/queryRunTimes")
    public Result<List<RunTime>> queryRunTimes(String days) {
        return Result.success(bigStorageCageHistoryTaskService.queryRunTimes(days));
    }
}
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/bigstoragecagetask/mapper/BigStorageCageHistoryTaskMapper.java
@@ -19,6 +19,6 @@
    DailyProductionVO queryBigDailyProduction(@Param("beginDate") String beginDate, @Param("endDate") String endDate);
    List<RunTime> queryRunTimes();
    List<RunTime> queryRunTimes(@Param("days") String days);
}
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/bigstoragecagetask/service/BigStorageCageHistoryTaskService.java
@@ -22,6 +22,6 @@
    DailyProductionVO queryBigDailyProduction(BigStorageCageHistoryRequest request);
    List<RunTime> queryRunTimes();
    List<RunTime> queryRunTimes(String days);
}
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/bigstoragecagetask/service/impl/BigStorageCageHistoryTaskServiceImpl.java
@@ -58,8 +58,8 @@
    }
    @Override
    public List<RunTime> queryRunTimes(){
        return baseMapper.queryRunTimes();
    public List<RunTime> queryRunTimes(String days){
        return baseMapper.queryRunTimes(days);
    }
}
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/job/OPCPlcSlicecage.java
@@ -27,6 +27,8 @@
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
import java.time.LocalDate;
import java.time.format.DateTimeFormatter;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
@@ -220,7 +222,7 @@
            jsonObject.append("bigStorageCageUsage", bigStorageCageUsage);
            List<PieChartVO> pieChartVOS = bigStorageCageService.queryPieChart();
            jsonObject.append("pieChartVOS", pieChartVOS);
            List<RunTime> tempRunTimes = bigStorageCageHistoryTaskService.queryRunTimes();
            List<RunTime> tempRunTimes = bigStorageCageHistoryTaskService.queryRunTimes(LocalDate.now().format(DateTimeFormatter.ofPattern("yyyy-MM-dd")));
            jsonObject.append("tempRunTimes", tempRunTimes);
            for (WebSocketServer webserver : sendwServer) {
                if (webserver != null) {
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/resources/mapper/BigStorageCageHistoryTaskMapper.xml
@@ -48,7 +48,7 @@
            select distinct create_time
            from big_storage_cage_history_task
            where task_type = 2
              and create_time BETWEEN CURDATE() AND DATE_ADD(CURDATE(), INTERVAL 1 DAY)
              and create_time LIKE '%${days}%'
        )
        SELECT t1.create_time                                                    AS first_timestamp,
               t2.create_time                                                    AS second_timestamp,
hangzhoumesParent/moduleService/hollowGlassModule/src/main/java/com/mes/hollowtask/controller/HollowBigStorageCageHistoryTaskController.java
@@ -6,16 +6,15 @@
import com.mes.hollowtask.entity.request.HollowBigStorageCageHistoryRequest;
import com.mes.hollowtask.service.HollowBigStorageCageHistoryTaskService;
import com.mes.largenscreen.entity.DailyProductionVO;
import com.mes.largenscreen.entity.RunTime;
import com.mes.utils.Result;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource;
import java.util.List;
/**
 * (HollowBigStorageCageHistoryTask)表控制层
@@ -42,5 +41,11 @@
    public Result<DailyProductionVO> queryHollowDailyProduction(@RequestBody HollowBigStorageCageHistoryRequest request) {
        return Result.success(hollowBigStorageCageHistoryTaskService.queryHollowDailyProduction(request));
    }
    @ApiOperation(value = "查询生产线运行情况", notes = "查询生产线运行情况")
    @GetMapping("/queryRunTimes")
    public Result<List<RunTime>> queryRunTimes(String days) {
        return Result.success(hollowBigStorageCageHistoryTaskService.queryRunTimes(days));
    }
}
hangzhoumesParent/moduleService/hollowGlassModule/src/main/java/com/mes/hollowtask/mapper/HollowBigStorageCageHistoryTaskMapper.java
@@ -18,6 +18,6 @@
    DailyProductionVO queryHollowDailyProduction(@Param("beginDate") String beginDate, @Param("endDate") String endDate);
    List<RunTime> queryRunTimes();
    List<RunTime> queryRunTimes(@Param("days") String days);
}
hangzhoumesParent/moduleService/hollowGlassModule/src/main/java/com/mes/hollowtask/service/HollowBigStorageCageHistoryTaskService.java
@@ -21,6 +21,6 @@
    DailyProductionVO queryHollowDailyProduction(HollowBigStorageCageHistoryRequest request);
    List<RunTime> queryRunTimes();
    List<RunTime> queryRunTimes(String days);
}
hangzhoumesParent/moduleService/hollowGlassModule/src/main/java/com/mes/hollowtask/service/impl/HollowBigStorageCageHistoryTaskServiceImpl.java
@@ -57,8 +57,8 @@
    }
    @Override
    public List<RunTime> queryRunTimes(){
        return baseMapper.queryRunTimes();
    public List<RunTime> queryRunTimes(String days){
        return baseMapper.queryRunTimes(days);
    }
}
hangzhoumesParent/moduleService/hollowGlassModule/src/main/java/com/mes/job/PushMessageToIndex.java
@@ -30,6 +30,8 @@
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
import java.time.LocalDate;
import java.time.format.DateTimeFormatter;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
@@ -234,7 +236,7 @@
        //钢化饼图数据
        List<PieChartVO> pieChartVOS = hollowGlassOutRelationInfoService.queryPieChart();
        jsonObject.append("pieChartVOS", pieChartVOS);
        List<RunTime> hollowRunTimes = hollowBigStorageCageHistoryTaskService.queryRunTimes();
        List<RunTime> hollowRunTimes = hollowBigStorageCageHistoryTaskService.queryRunTimes(LocalDate.now().format(DateTimeFormatter.ofPattern("yyyy-MM-dd")));
        jsonObject.append("hollowRunTimes", hollowRunTimes);
        ArrayList<WebSocketServer> sendwServer = WebSocketServer.sessionMap.get("largenScreen");
        if (sendwServer != null) {
hangzhoumesParent/moduleService/hollowGlassModule/src/main/resources/mapper/HollowBigStorageCageHistoryTaskMapper.xml
@@ -50,12 +50,14 @@
    <select id="queryRunTimes" resultType="com.mes.largenscreen.entity.RunTime">
        with big_storage_cage_history_task_temp as (
            select distinct create_time from hollow_big_storage_cage_history_task  where task_type = 5 and
                create_time  BETWEEN    CURDATE() AND DATE_ADD(CURDATE(), INTERVAL 1 DAY)
                create_time  LIKE '%${days}%'
        )
        SELECT
            t1.create_time AS first_timestamp,
            t2.create_time AS second_timestamp,
            TIMESTAMPDIFF(MINUTE, t1.create_time, t2.create_time) as diff_minutes
            TIMESTAMPDIFF(MINUTE, t1.create_time, t2.create_time) as diff_minutes,
               (select min(create_time) from big_storage_cage_history_task_temp) as start_timestamp
                ,(select max(create_time) from big_storage_cage_history_task_temp) as end_timestamp
        FROM
            (SELECT
                 create_time,