From 1bfb11845bb897be403d2df9ad5a31fb265d4e8a Mon Sep 17 00:00:00 2001 From: gaoqr <13665037151@163.com> Date: Tue, 9 Jun 2026 17:54:22 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A6=85=E9=81=93bug#1654=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../plan/saveOptimize/NoPlanFilterPlateReqVO.java | 4 ++++ .../executor/dal/mysql/plate/PlateMapper.java | 6 +++++- .../optimizeplan/OptimizePlanServiceImpl.java | 3 ++- .../main/resources/mapper/plate/PlateMapper.xml | 14 +++++++++++++- 4 files changed, 24 insertions(+), 3 deletions(-) diff --git a/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/java/com/cf/imes/module/executor/controller/admin/plan/saveOptimize/NoPlanFilterPlateReqVO.java b/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/java/com/cf/imes/module/executor/controller/admin/plan/saveOptimize/NoPlanFilterPlateReqVO.java index 619a4d7c6..2f17c20c9 100644 --- a/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/java/com/cf/imes/module/executor/controller/admin/plan/saveOptimize/NoPlanFilterPlateReqVO.java +++ b/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/java/com/cf/imes/module/executor/controller/admin/plan/saveOptimize/NoPlanFilterPlateReqVO.java @@ -25,5 +25,9 @@ public class NoPlanFilterPlateReqVO { @NotEmpty(message = "大板ID不能为空") private List goodsIdList; + @Schema(description = "柜体ID列表") + private List bodyIds; + @Schema(description = "房间ID列表") + private List roomIds; } diff --git a/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/java/com/cf/imes/module/executor/dal/mysql/plate/PlateMapper.java b/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/java/com/cf/imes/module/executor/dal/mysql/plate/PlateMapper.java index 5d97a0fa3..06dd13b93 100644 --- a/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/java/com/cf/imes/module/executor/dal/mysql/plate/PlateMapper.java +++ b/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/java/com/cf/imes/module/executor/dal/mysql/plate/PlateMapper.java @@ -204,7 +204,11 @@ public interface PlateMapper extends BaseMapperX { * @param organId * @return */ - List selectNoPlanPlate(@Param("orderIds") List orderIds, @Param("ids") List ids, @Param("organId") Long organId); + List selectNoPlanPlate(@Param("orderIds") List orderIds, + @Param("ids") List ids, + @Param("roomIds") List roomIdList, + @Param("bodyIds") List bodyIdList, + @Param("organId") Long organId); /** * 查询未排单板件(带添加小板筛选) diff --git a/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/java/com/cf/imes/module/executor/service/optimizeplan/OptimizePlanServiceImpl.java b/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/java/com/cf/imes/module/executor/service/optimizeplan/OptimizePlanServiceImpl.java index 49542bf93..229435bf3 100644 --- a/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/java/com/cf/imes/module/executor/service/optimizeplan/OptimizePlanServiceImpl.java +++ b/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/java/com/cf/imes/module/executor/service/optimizeplan/OptimizePlanServiceImpl.java @@ -779,7 +779,8 @@ public class OptimizePlanServiceImpl implements OptimizePlanService { } // 查询未排单小板 - List plateDetailRespVOS = plateMapper.selectNoPlanPlate(orderIds, orderGoodsIds, getUserOrganId()); + List plateDetailRespVOS = plateMapper.selectNoPlanPlate( + orderIds, orderGoodsIds, reqVO.getRoomIds(), reqVO.getBodyIds(), getUserOrganId()); AssertUtils.notEmpty(plateDetailRespVOS, ORDER_PLATE_EMPTY); diff --git a/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/resources/mapper/plate/PlateMapper.xml b/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/resources/mapper/plate/PlateMapper.xml index f703a5ea0..a4aa17cc1 100644 --- a/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/resources/mapper/plate/PlateMapper.xml +++ b/cf-module-prod-executor/cf-module-prod-executor-biz/src/main/resources/mapper/plate/PlateMapper.xml @@ -488,7 +488,7 @@ AND op.order_id = ogs.order_id AND op.goods_id = ogs.id - LEFT JOIN ( + JOIN ( SELECT plate_id, group_id, comp_id @@ -500,6 +500,18 @@ #{orderIds} and organ_id = #{organId} + + AND room_id IN + + #{roomIdItem} + + + + AND body_id IN + + #{bodyIdItem} + + GROUP BY plate_id, group_id, comp_id ) oi ON op.id = oi.plate_id