From 4a71c21c9bcf68a7cb5076db6f2b9c8ab527316a Mon Sep 17 00:00:00 2001 From: Comair <1464848666@qq.com> Date: Mon, 1 Jul 2024 16:12:46 +0800 Subject: [PATCH] =?UTF-8?q?=E6=89=8B=E5=8A=A8=E4=B8=8B=E5=8F=91=E9=A2=9C?= =?UTF-8?q?=E8=89=B2=E4=B8=8B=E6=8B=89=E9=97=AE=E9=A2=98=20=E5=A4=A7?= =?UTF-8?q?=E5=B1=8Fagv=E7=BC=96=E5=8F=B7=E6=8E=92=E5=BA=8F=E9=97=AE?= =?UTF-8?q?=E9=A2=98=20=E5=A0=86=E5=9E=9B=E6=9C=BA=E7=BC=96=E5=8F=B7?= =?UTF-8?q?=E6=8E=92=E5=BA=8F=E9=97=AE=E9=A2=98=20=E7=B4=A7=E6=80=A5?= =?UTF-8?q?=E5=87=BA=E5=BA=93=E7=82=B9=E4=BD=8D=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/shkj/wms/constants/ParameterConstants.java | 5 ++++- .../src/main/java/com/shkj/wms/plc/PlcEventTask.java | 12 ++++++------ .../wms/service/impl/BusinDataTaskServiceImpl.java | 10 ++++------ .../shkj/wms/service/impl/WcsDeviceServiceImpl.java | 4 ++++ .../main/resources/mapper/wms/BaseDeriveMapper.xml | 2 +- 5 files changed, 19 insertions(+), 14 deletions(-) diff --git a/shkj-wms/src/main/java/com/shkj/wms/constants/ParameterConstants.java b/shkj-wms/src/main/java/com/shkj/wms/constants/ParameterConstants.java index 28b6440..c3d0f34 100644 --- a/shkj-wms/src/main/java/com/shkj/wms/constants/ParameterConstants.java +++ b/shkj-wms/src/main/java/com/shkj/wms/constants/ParameterConstants.java @@ -75,9 +75,12 @@ public final class ParameterConstants { //人工下挂点 public final static String Manual_drop_point= "Manual_drop_point"; - //紧急出库接驳点点位 + //紧急出库接驳点点位 分组 public final static String urgency_out_point="urgency_out_point"; + //紧急出库接驳点点位 + public final static String urgent_out_point="urgent_out_point"; + //平库入库接驳口 public final static String P_in01="KW18"; //平库出库接驳口 diff --git a/shkj-wms/src/main/java/com/shkj/wms/plc/PlcEventTask.java b/shkj-wms/src/main/java/com/shkj/wms/plc/PlcEventTask.java index a20bd70..88cd94a 100644 --- a/shkj-wms/src/main/java/com/shkj/wms/plc/PlcEventTask.java +++ b/shkj-wms/src/main/java/com/shkj/wms/plc/PlcEventTask.java @@ -167,7 +167,7 @@ public class PlcEventTask { plcInit.connect(conn.getPlcIp()); } plcTask(plcOperate_60, conn, conn.getPointTables()); - doDevStatus(plcOperate_60,"1#"); + doDevStatus(plcOperate_60,"1"); } if(conn.getPlcIp().contains(".70")){ @@ -176,7 +176,7 @@ public class PlcEventTask { plcInit.connect(conn.getPlcIp()); } plcTask(plcOperate_70, conn, conn.getPointTables()); - doDevStatus(plcOperate_70,"2#"); + doDevStatus(plcOperate_70,"2"); } if(conn.getPlcIp().contains(".80")){ @@ -185,7 +185,7 @@ public class PlcEventTask { plcInit.connect(conn.getPlcIp()); } plcTask(plcOperate_80, conn, conn.getPointTables()); - doDevStatus(plcOperate_80,"3#"); + doDevStatus(plcOperate_80,"3"); } if(conn.getPlcIp().contains(".90")){ @@ -194,7 +194,7 @@ public class PlcEventTask { plcInit.connect(conn.getPlcIp()); } plcTask(plcOperate_90, conn, conn.getPointTables()); - doDevStatus(plcOperate_90,"4#"); + doDevStatus(plcOperate_90,"4"); } if(conn.getPlcIp().contains(".100")){ @@ -203,7 +203,7 @@ public class PlcEventTask { plcInit.connect(conn.getPlcIp()); } plcTask(plcOperate_100, conn, conn.getPointTables()); - doDevStatus(plcOperate_100,"5#"); + doDevStatus(plcOperate_100,"5"); } if(conn.getPlcIp().contains(".110")){ @@ -212,7 +212,7 @@ public class PlcEventTask { plcInit.connect(conn.getPlcIp()); } plcTask(plcOperate_110, conn, conn.getPointTables()); - doDevStatus(plcOperate_110,"6#"); + doDevStatus(plcOperate_110,"6"); } } } diff --git a/shkj-wms/src/main/java/com/shkj/wms/service/impl/BusinDataTaskServiceImpl.java b/shkj-wms/src/main/java/com/shkj/wms/service/impl/BusinDataTaskServiceImpl.java index 38e0410..43de60a 100644 --- a/shkj-wms/src/main/java/com/shkj/wms/service/impl/BusinDataTaskServiceImpl.java +++ b/shkj-wms/src/main/java/com/shkj/wms/service/impl/BusinDataTaskServiceImpl.java @@ -428,13 +428,11 @@ public class BusinDataTaskServiceImpl extends ServiceImpl taskList = new ArrayList<>(); List taskGoodsList = new ArrayList<>(); //获取出库组装接驳点位 - String pointout = sysParameterService.selectConfigByKey(ParameterConstants.ParameterSystem.urgency_out_point); - BasePointDeviceQueryBo pointQueryBo = new BasePointDeviceQueryBo(); - - pointQueryBo.setGroupNo(pointout); - BasePointDeviceVo pointDeviceout = basePointDeviceMapper.selectBasePointByGroupno(pointQueryBo); - String urgency=pointDeviceout.getPointNo(); + String urgency= sysParameterService.selectConfigByKey(ParameterConstants.ParameterSystem.urgent_out_point); + if (StringUtils.isEmpty(urgency)){ + return Result.err().msg("未设定紧急出库接驳点"); + } //一套保险杠 if (isSuite){ diff --git a/shkj-wms/src/main/java/com/shkj/wms/service/impl/WcsDeviceServiceImpl.java b/shkj-wms/src/main/java/com/shkj/wms/service/impl/WcsDeviceServiceImpl.java index 1420909..a337bdf 100644 --- a/shkj-wms/src/main/java/com/shkj/wms/service/impl/WcsDeviceServiceImpl.java +++ b/shkj-wms/src/main/java/com/shkj/wms/service/impl/WcsDeviceServiceImpl.java @@ -18,8 +18,10 @@ import org.springframework.data.redis.core.RedisTemplate; import org.springframework.stereotype.Service; import java.util.ArrayList; +import java.util.Comparator; import java.util.List; import java.util.Set; +import java.util.stream.Stream; /** * 设备管理Service业务层处理 @@ -131,12 +133,14 @@ public class WcsDeviceServiceImpl extends ServiceImpl getAGVRealStatesInfo() { List list =(List)redisTemplate.opsForValue().get(RedisConstant.redisAgvRealInfo ); + list.stream().sorted(Comparator.comparing(BusinAgvRealRedisInfo::getId)); return list; } diff --git a/shkj-wms/src/main/resources/mapper/wms/BaseDeriveMapper.xml b/shkj-wms/src/main/resources/mapper/wms/BaseDeriveMapper.xml index 96f51af..ef7dce2 100644 --- a/shkj-wms/src/main/resources/mapper/wms/BaseDeriveMapper.xml +++ b/shkj-wms/src/main/resources/mapper/wms/BaseDeriveMapper.xml @@ -123,7 +123,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" AND derive.derive =#{derive} - AND derive.vehiche_code =#{vehicheModel} + AND derive.vehiche_model =#{vehicheModel}