From 46054fc49e33fe4f1aba8da23b74b8f14664bdfe Mon Sep 17 00:00:00 2001
From: Junjie <xjj@123>
Date: 星期日, 28 四月 2024 09:06:42 +0800
Subject: [PATCH] #

---
 zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/core/service/impl/MainServiceImpl.java |   16 +++++++++++-----
 1 files changed, 11 insertions(+), 5 deletions(-)

diff --git a/zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/core/service/impl/MainServiceImpl.java b/zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/core/service/impl/MainServiceImpl.java
index 74784be..741bed4 100644
--- a/zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/core/service/impl/MainServiceImpl.java
+++ b/zy-asrs-wcs/src/main/java/com/zy/asrs/wcs/core/service/impl/MainServiceImpl.java
@@ -6,6 +6,7 @@
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.zy.asrs.framework.common.Cools;
 import com.zy.asrs.framework.common.SnowflakeIdWorker;
+import com.zy.asrs.wcs.core.domain.dto.RedisMapDto;
 import com.zy.asrs.wcs.core.entity.*;
 import com.zy.asrs.wcs.core.kernel.AnalyzeService;
 import com.zy.asrs.wcs.core.model.MapNode;
@@ -174,11 +175,11 @@
 
                 Integer lev = entry.getKey();
                 Date now = new Date();
-                HashMap<String, Object> map = new HashMap<>();
-                map.put("data", JSON.toJSONString(lists));
-                map.put("create_time", now);
-                map.put("update_time", now);
-                map.put("lev", lev);
+                RedisMapDto map = new RedisMapDto();
+                map.setData(JSON.toJSONString(lists));
+                map.setCreateTime(now);
+                map.setUpdateTime(now);
+                map.setLev(lev);
 
                 //灏嗗湴鍥炬暟鎹瓨鍏edis
                 redisUtil.set(DeviceRedisConstant.MAP + lev, JSON.toJSONString(map));
@@ -441,6 +442,11 @@
                 continue;
             }
 
+            ShuttleProtocol shuttleProtocol = shuttleThread.getStatus();
+            if (shuttleProtocol == null) {
+                continue;
+            }
+
             if (!shuttleThread.isCharging()) {
                 continue;
             }

--
Gitblit v1.9.1