From 8adb57108b77cdab89594a8065f7c247aff11e6a Mon Sep 17 00:00:00 2001
From: 严智鑫 <test>
Date: 星期五, 14 六月 2024 14:50:14 +0800
Subject: [PATCH] 删除glassinfo
---
hangzhoumesParent/moduleService/CacheGlassModule/src/test/java/com/mes/CacheGlassModuleApplicationTest.java | 5 --
/dev/null | 60 ------------------------------
hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/taskcache/service/impl/TaskCacheServiceImpl.java | 2 -
hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/job/CacheGlassTask.java | 3 -
hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/taskcache/service/TaskCacheService.java | 10 +++++
5 files changed, 10 insertions(+), 70 deletions(-)
diff --git a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/glassinfo/controller/GlassInfoController.java b/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/glassinfo/controller/GlassInfoController.java
deleted file mode 100644
index 08fa5a6..0000000
--- a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/glassinfo/controller/GlassInfoController.java
+++ /dev/null
@@ -1,54 +0,0 @@
-package com.mes.glassinfo.controller;
-
-import com.mes.glassinfo.entity.GlassInfo;
-import com.mes.glassinfo.service.GlassInfoService;
-import com.mes.utils.Result;
-import io.swagger.annotations.Api;
-import io.swagger.annotations.ApiOperation;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.web.bind.annotation.PostMapping;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.ResponseBody;
-import org.springframework.web.bind.annotation.RestController;
-
-import java.util.List;
-
-/**
- * <p>
- * 鍓嶇鎺у埗鍣�
- * </p>
- *
- * @author zhoush
- * @since 2024-04-07
- */
-@Api(description = "鐜荤拑淇℃伅灏忕墖")
-@RestController
-@RequestMapping("/glassInfo")
-public class GlassInfoController {
-
- @Autowired
- private GlassInfoService glassInfoService;
-
- @ApiOperation("鏍规嵁鐜荤拑灏忕墖ID鏌ヨ 鐜荤拑鏁版嵁锛氬弬鏁�(鐜荤拑ID)")
- @PostMapping("/selectId")
- @ResponseBody
- public Result selectId(String ProcessId) {
- List<GlassInfo> list = glassInfoService.selectId(ProcessId);
- return Result.build(200,"鎴愬姛",list);
- }
- @ApiOperation("鏌ヨ鎵�鏈夌幓鐠冨皬鐗囦俊鎭� 鐜荤拑鏁版嵁 鍙傛暟()")
- @PostMapping("/selectAll")
- @ResponseBody
- public Result selectAll() {
- List<GlassInfo> list = glassInfoService.selectAll();
- return Result.build(200,"鎴愬姛",list);
- }
- @ApiOperation("鏌ヨ宸ョ▼涓嬬殑鐜荤拑灏忕墖淇℃伅 鐜荤拑鏁版嵁 鍙傛暟(宸ョ▼鍙�)")
- @PostMapping("/selectFlowCardId")
- @ResponseBody
- public Result selectFlowCardId(String flowCardId) {
- List<GlassInfo> list = glassInfoService.selectFlowCardId(flowCardId);
- return Result.build(200,"鎴愬姛",list);
- }
-}
-
diff --git a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/glassinfo/mapper/GlassInfoMapper.java b/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/glassinfo/mapper/GlassInfoMapper.java
deleted file mode 100644
index ade0460..0000000
--- a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/glassinfo/mapper/GlassInfoMapper.java
+++ /dev/null
@@ -1,17 +0,0 @@
-package com.mes.glassinfo.mapper;
-
-import com.baomidou.mybatisplus.core.mapper.BaseMapper;
-import com.github.yulichang.base.MPJBaseMapper;
-import com.mes.glassinfo.entity.GlassInfo;
-
-/**
- * <p>
- * Mapper 鎺ュ彛
- * </p>
- *
- * @author zhoush
- * @since 2024-04-07
- */
-public interface GlassInfoMapper extends MPJBaseMapper<GlassInfo> {
-
-}
diff --git a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/glassinfo/service/GlassInfoService.java b/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/glassinfo/service/GlassInfoService.java
deleted file mode 100644
index f5117b0..0000000
--- a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/glassinfo/service/GlassInfoService.java
+++ /dev/null
@@ -1,37 +0,0 @@
-package com.mes.glassinfo.service;
-
-import com.baomidou.mybatisplus.extension.service.IService;
-import com.mes.glassinfo.entity.GlassInfo;
-
-import java.util.List;
-
-/**
- * <p>
- * 鏈嶅姟绫�
- * </p>
- *
- * @author zhoush
- * @since 2024-04-07
- */
-public interface GlassInfoService extends IService<GlassInfo> {
-
- /**
- * 鏌ヨ鎵�鏈夌幓鐠冨皬鐗囦俊鎭�
- * @return
- */
- public List<GlassInfo> selectAll();
-
- /**
- * 鏍规嵁鐜荤拑缂栧彿鏌ヨ鐜荤拑灏忕墖淇℃伅
- * @param glassId
- * @return
- */
- public List<GlassInfo> selectId(String glassId);
-
- /**
- * 鏍规嵁宸ョ▼鍙锋煡璇㈢幓鐠冨皬鐗囦俊鎭�
- * @param flowCardId
- * @return
- */
- public List<GlassInfo> selectFlowCardId(String flowCardId);
-}
diff --git a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/glassinfo/service/impl/GlassInfoServiceImpl.java b/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/glassinfo/service/impl/GlassInfoServiceImpl.java
deleted file mode 100644
index 7e04d74..0000000
--- a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/glassinfo/service/impl/GlassInfoServiceImpl.java
+++ /dev/null
@@ -1,60 +0,0 @@
-package com.mes.glassinfo.service.impl;
-
-import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
-import com.github.yulichang.query.MPJLambdaQueryWrapper;
-import com.github.yulichang.wrapper.MPJLambdaWrapper;
-import com.mes.glassinfo.entity.GlassInfo;
-import com.mes.glassinfo.mapper.GlassInfoMapper;
-import com.mes.glassinfo.service.GlassInfoService;
-import com.mes.taskcache.entity.TaskCache;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-
-import java.util.List;
-import java.util.Map;
-
-/**
- * <p>
- * 鏈嶅姟瀹炵幇绫�
- * </p>
- *
- * @author zhoush
- * @since 2024-04-07
- */
-@Service
-public class GlassInfoServiceImpl extends ServiceImpl<GlassInfoMapper, GlassInfo> implements GlassInfoService {
-
-
- /**
- * 鏍规嵁ID 鑾峰彇灏忕墖鏁版嵁
- * @param glassId
- * @return
- */
- @Override
- public List<GlassInfo> selectId(String glassId){
- return baseMapper.selectList(new MPJLambdaWrapper<GlassInfo>().selectAll(GlassInfo.class).eq(GlassInfo::getGlassId,glassId));
-// return baseMapper.selectList(new QueryWrapper<GlassInfo>().eq("glass_id",glassId));
- };
-
- /**
- * 鑾峰彇鍏ㄩ儴灏忕墖鏁版嵁
- * @return
- */
- @Override
- public List<GlassInfo> selectAll(){
- return baseMapper.selectList(null);
- };
-
- /**
- * 鏍规嵁宸ョ▼ 鑾峰彇灏忕墖鏁版嵁
- * @param flowCardId
- * @return
- */
- @Override
- public List<GlassInfo> selectFlowCardId(String flowCardId){
- return baseMapper.selectList(new MPJLambdaWrapper<GlassInfo>().selectAll(GlassInfo.class).eq(GlassInfo::getFlowCardId,flowCardId));
- //Sql鐗堟湰
-// return baseMapper.selectList(new QueryWrapper<GlassInfo>().eq("flow_card_id",flowCardId));
- };
-}
diff --git a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/job/CacheGlassTask.java b/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/job/CacheGlassTask.java
index 17b7195..a63c890 100644
--- a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/job/CacheGlassTask.java
+++ b/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/job/CacheGlassTask.java
@@ -672,7 +672,6 @@
List<Map<String,Object>> EdgTasks2 = taskCacheService.selectEdgInfo("2002");
jsonObject.append("EdgTasks1", EdgTasks1);
jsonObject.append("EdgTasks2", EdgTasks2);
- log.info("纾ㄨ竟浠诲姟{}",jsonObject);
ArrayList<WebSocketServer> sendwServer = WebSocketServer.sessionMap.get("cacheGlass");
if (sendwServer != null) {
for (WebSocketServer webserver : sendwServer) {
@@ -701,10 +700,8 @@
JSONObject jsonObject = new JSONObject();
List<Map<String, Object>> EdgStorageCageinfos=edgStorageCageService.selectEdgStorageCages();
jsonObject.append("EdgStorageCageinfos", EdgStorageCageinfos);
- log.info("绗煎唴淇℃伅{}",EdgStorageCageinfos);
ArrayList<WebSocketServer> sendwServer = WebSocketServer.sessionMap.get("cacheGlass");
if (sendwServer != null) {
-
for (WebSocketServer webserver : sendwServer) {
if (webserver != null) {
webserver.sendMessage(jsonObject.toString());
diff --git a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/taskcache/service/TaskCacheService.java b/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/taskcache/service/TaskCacheService.java
index c474e1f..239fabe 100644
--- a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/taskcache/service/TaskCacheService.java
+++ b/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/taskcache/service/TaskCacheService.java
@@ -20,13 +20,23 @@
boolean insertTaskCache(TaskCache taskCache);
/**
* 鏌ヨ纾ㄨ竟浠诲姟
+ *
* @param line
* @return
*/
List<Map<String,Object>> selectEdgInfo(String line);
/**
+ * 鏌ヨ纾ㄨ竟浠诲姟
+ *
+ * @param line
+ * @return
+ */
+ TaskCache queryGlassByTaskCache(int line, List<Integer> taskTypes);
+
+ /**
* 鏌ヨ鐞嗙墖浠诲姟
+ *
* @return
*/
List<TaskCache> selectCacheInfo();
diff --git a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/taskcache/service/impl/TaskCacheServiceImpl.java b/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/taskcache/service/impl/TaskCacheServiceImpl.java
index fbd5156..3b56659 100644
--- a/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/taskcache/service/impl/TaskCacheServiceImpl.java
+++ b/hangzhoumesParent/moduleService/CacheGlassModule/src/main/java/com/mes/taskcache/service/impl/TaskCacheServiceImpl.java
@@ -17,7 +17,6 @@
import java.util.HashMap;
import java.util.List;
import java.util.Map;
-import java.util.stream.Collectors;
/**
* <p>
@@ -60,7 +59,6 @@
.orderByAsc(TaskCache::getCreateTime));
List<Map<String,Object>> result=new ArrayList<>();
int serialNumber=1;
- List<Map<String,Object>> a=taskCache.stream().filter(t->t.getTaskStatus()==1).collect(Collectors.toList());
for(TaskCache taskCache1:taskCache){
Map<String,Object> map=new HashMap<>();
GlassInfo glassInfo=glassInfoMapper.selectOne(new MPJLambdaWrapper<GlassInfo>()
diff --git a/hangzhoumesParent/moduleService/CacheGlassModule/src/test/java/com/mes/CacheGlassModuleApplicationTest.java b/hangzhoumesParent/moduleService/CacheGlassModule/src/test/java/com/mes/CacheGlassModuleApplicationTest.java
index 0f57394..4bf1348 100644
--- a/hangzhoumesParent/moduleService/CacheGlassModule/src/test/java/com/mes/CacheGlassModuleApplicationTest.java
+++ b/hangzhoumesParent/moduleService/CacheGlassModule/src/test/java/com/mes/CacheGlassModuleApplicationTest.java
@@ -112,11 +112,6 @@
log.info("Sql鏁版嵁锛歿}", Arrays.asList(list));
}
- @Test
- public void testglassinfo() {
- List<GlassInfo> glassInfos = glassInfoService.selectId("7");
- log.info("鐜荤拑鏁版嵁鏁版嵁锛歿}", Arrays.asList(glassInfos));
- }
@Test
public void testCacheGlass() {
--
Gitblit v1.8.0