From f5e1d6b6dc0488812bf808b1b46cd1433e8c0ee5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B8=B8=E7=86=9F=E5=90=B4=E5=BD=A6=E7=A5=96?= Date: Tue, 21 Oct 2025 18:36:18 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E9=BD=90=E5=A5=97=E8=BF=90?= =?UTF-8?q?=E8=BE=93=E7=9B=B8=E5=85=B3=E5=AE=9E=E4=BD=93=E7=B1=BB=E3=80=81?= =?UTF-8?q?Mapper=E6=8E=A5=E5=8F=A3=E5=8F=8A=E6=9C=8D=E5=8A=A1=E5=AE=9E?= =?UTF-8?q?=E7=8E=B0=EF=BC=8C=E4=BC=98=E5=8C=96=E9=BD=90=E5=A5=97=E8=BF=90?= =?UTF-8?q?=E8=BE=93=E4=BB=BB=E5=8A=A1=E5=A4=84=E7=90=86=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../automatedWarehouse/mapper/WcsIntegrationMapper.java | 2 +- .../service/impl/AutoTaskServiceImpl.java | 6 ++++++ .../service/impl/WcsIntegrationServiceImpl.java | 6 ++++++ .../mapper/automatedWarehouse/WcsIntegrationMapper.xml | 6 ++++++ 4 files changed, 19 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/gaotao/modules/automatedWarehouse/mapper/WcsIntegrationMapper.java b/src/main/java/com/gaotao/modules/automatedWarehouse/mapper/WcsIntegrationMapper.java index ed0b929..2f634b3 100644 --- a/src/main/java/com/gaotao/modules/automatedWarehouse/mapper/WcsIntegrationMapper.java +++ b/src/main/java/com/gaotao/modules/automatedWarehouse/mapper/WcsIntegrationMapper.java @@ -376,7 +376,7 @@ public interface WcsIntegrationMapper { * 获取AGV站点状态 - AI制作 */ Integer getAgvStationStatus(@Param("stationCode") String stationCode); - + String getAgvStationType(@Param("stationCode") String stationCode); /** * 获取栈板详细信息(包含palletType和autoSort以及托盘类型详情) - AI制作 */ diff --git a/src/main/java/com/gaotao/modules/automatedWarehouse/service/impl/AutoTaskServiceImpl.java b/src/main/java/com/gaotao/modules/automatedWarehouse/service/impl/AutoTaskServiceImpl.java index 40a78c5..6c6a054 100644 --- a/src/main/java/com/gaotao/modules/automatedWarehouse/service/impl/AutoTaskServiceImpl.java +++ b/src/main/java/com/gaotao/modules/automatedWarehouse/service/impl/AutoTaskServiceImpl.java @@ -328,12 +328,18 @@ public class AutoTaskServiceImpl implements AutoTaskService { // 校验当前站点是否空闲 - rqrq Integer stationStatus = wcsIntegrationMapper.getAgvStationStatus(inData.getFromLocation()); + + String stationType = wcsIntegrationMapper.getAgvStationType(inData.getFromLocation()); + if(!"正式站点".equals(stationType)){ + throw new RuntimeException("只有正式站点可以启用AGV托运!"); + } if(stationStatus == null){ throw new RuntimeException("起始站点不存在:" + inData.getFromLocation()); } if(stationStatus != 1){ throw new RuntimeException("起始站点不是有货状态,当前状态码:" + stationStatus); } + System.out.println("栈板和站点状态校验通过 - rqrq"); } diff --git a/src/main/java/com/gaotao/modules/automatedWarehouse/service/impl/WcsIntegrationServiceImpl.java b/src/main/java/com/gaotao/modules/automatedWarehouse/service/impl/WcsIntegrationServiceImpl.java index a526c2f..9e0ff1a 100644 --- a/src/main/java/com/gaotao/modules/automatedWarehouse/service/impl/WcsIntegrationServiceImpl.java +++ b/src/main/java/com/gaotao/modules/automatedWarehouse/service/impl/WcsIntegrationServiceImpl.java @@ -427,6 +427,12 @@ public class WcsIntegrationServiceImpl implements WcsIntegrationService { //初始化的时候用 一开始栈板是没有位置的 按照第一个入栈的标签来给虚拟位置 后期不需要处理 if("TEMP".equals(labelWarehouseId)){ wcsIntegrationMapper.updatePalletLocationCode(site, palletId, "TEMP"); + }else if("W01".equals(labelWarehouseId)){ + wcsIntegrationMapper.updatePalletLocationCode(site, palletId, "W01"); + }else if("Q01".equals(labelWarehouseId)){ + wcsIntegrationMapper.updatePalletLocationCode(site, palletId, "Q01"); + }else if("W02".equals(labelWarehouseId)){ + wcsIntegrationMapper.updatePalletLocationCode(site, palletId, "W02"); }else if("AS".equals(labelLocationId)){ wcsIntegrationMapper.updatePalletLocationCode(site, palletId, "Virtual_AS"); }else { diff --git a/src/main/resources/mapper/automatedWarehouse/WcsIntegrationMapper.xml b/src/main/resources/mapper/automatedWarehouse/WcsIntegrationMapper.xml index b87364a..33610c2 100644 --- a/src/main/resources/mapper/automatedWarehouse/WcsIntegrationMapper.xml +++ b/src/main/resources/mapper/automatedWarehouse/WcsIntegrationMapper.xml @@ -815,6 +815,12 @@ WHERE station_code = #{stationCode} + +