From 3ae980b77dcc341c524309e024f1dde72895c34a 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: Wed, 15 Oct 2025 15:29:24 +0800 Subject: [PATCH] bug --- .../impl/WcsIntegrationServiceImpl.java | 8 ++--- .../service/impl/LabelQueryServiceImpl.java | 34 +++++++++---------- 2 files changed, 20 insertions(+), 22 deletions(-) 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 deb9cea..f3ac16a 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 @@ -418,8 +418,8 @@ public class WcsIntegrationServiceImpl implements WcsIntegrationService { AgvStation nowStation = wcsIntegrationMapper.getNowStation(site, palletId); if (nowStation == null) { //初始化的时候用 一开始栈板是没有位置的 按照第一个入栈的标签来给虚拟位置 后期不需要处理 - if("Temp".equals(labelWarehouseId)){ - wcsIntegrationMapper.updatePalletLocationCode(site, palletId, "Temp"); + if("TEMP".equals(labelWarehouseId)){ + wcsIntegrationMapper.updatePalletLocationCode(site, palletId, "TEMP"); }else if("AS".equals(labelLocationId)){ wcsIntegrationMapper.updatePalletLocationCode(site, palletId, "Virtual_AS"); }else { @@ -428,6 +428,7 @@ public class WcsIntegrationServiceImpl implements WcsIntegrationService { } // 校验栈板和物料的仓库是否一致(栈板的仓库通过location_code关联agv_station获取warehouse_code) + nowStation=wcsIntegrationMapper.getNowStation(site, palletId); String palletWarehouseCode = nowStation.getWarehouseCode(); if (!labelWarehouseId.equals(palletWarehouseCode)) { throw new Exception("栈板和物料的仓库不同,无法进行打托操作"); @@ -1119,9 +1120,6 @@ public class WcsIntegrationServiceImpl implements WcsIntegrationService { String username = ((SysUserEntity) SecurityUtils.getSubject().getPrincipal()).getUsername(); // 更新栈板calling_flag为Y wcsIntegrationMapper.updatePalletCallingFlag(site, palletId, "Y", username); - }else { - //如果是分次组托 说明在分拣 需要查下是否有相关订单 - } Boolean boFlag="Y".equals(endFlag); //有常用料就有这个标记 diff --git a/src/main/java/com/gaotao/modules/warehouse/service/impl/LabelQueryServiceImpl.java b/src/main/java/com/gaotao/modules/warehouse/service/impl/LabelQueryServiceImpl.java index 521456e..b8ae0d1 100644 --- a/src/main/java/com/gaotao/modules/warehouse/service/impl/LabelQueryServiceImpl.java +++ b/src/main/java/com/gaotao/modules/warehouse/service/impl/LabelQueryServiceImpl.java @@ -101,23 +101,23 @@ public class LabelQueryServiceImpl implements LabelQueryService { // 校验库位是否存在以及是否属于指定仓库 - rqrq - if (dto.getLocationId() != null && !dto.getLocationId().isEmpty()) { - Location location = locationService.lambdaQuery() - .eq(Location::getSite, dto.getSite()) - .eq(Location::getLocationId, dto.getLocationId()) - .one(); - - if (location == null) { - throw new RuntimeException("库位【" + dto.getLocationId() + "】不存在"); - } - - // 检查库位是否属于指定仓库 - rqrq - if (dto.getWarehouseId() != null && !dto.getWarehouseId().isEmpty()) { - if (!dto.getWarehouseId().equals(location.getWarehouseId())) { - throw new RuntimeException("库位【" + dto.getLocationId() + "】不属于仓库【" + dto.getWarehouseId() + "】"); - } - } - } + // if (dto.getLocationId() != null && !dto.getLocationId().isEmpty() && !"TEMP".equals(dto.getWarehouseId())){ + // Location location = locationService.lambdaQuery() + // .eq(Location::getSite, dto.getSite()) + // .eq(Location::getLocationId, dto.getLocationId()) + // .one(); + // + // if (location == null) { + // throw new RuntimeException("库位【" + dto.getLocationId() + "】不存在"); + // } + // + // // 检查库位是否属于指定仓库 - rqrq + // if (dto.getWarehouseId() != null && !dto.getWarehouseId().isEmpty()) { + // if (!dto.getWarehouseId().equals(location.getWarehouseId())) { + // throw new RuntimeException("库位【" + dto.getLocationId() + "】不属于仓库【" + dto.getWarehouseId() + "】"); + // } + // } + // } // 更新HandlingUnit信息 - rqrq handlingUnit.setWarehouseId(dto.getWarehouseId());