From 050a6301777a6753c800f1999670f8d30f1589f9 Mon Sep 17 00:00:00 2001
From: liding <756868258@qq.com>
Date: 星期一, 27 四月 2026 17:55:51 +0800
Subject: [PATCH] feat:1.根据bom结构领料 2.额外领取库存产品
---
src/main/resources/mapper/production/ProductionBomStructureMapper.xml | 33 +++++++++++++++++++++++++++++++++
1 files changed, 33 insertions(+), 0 deletions(-)
diff --git a/src/main/resources/mapper/production/ProductionBomStructureMapper.xml b/src/main/resources/mapper/production/ProductionBomStructureMapper.xml
index 1f70c48..c116f6f 100644
--- a/src/main/resources/mapper/production/ProductionBomStructureMapper.xml
+++ b/src/main/resources/mapper/production/ProductionBomStructureMapper.xml
@@ -17,4 +17,37 @@
<result column="dept_id" property="deptId" />
</resultMap>
+ <select id="listByBomId" resultType="com.ruoyi.production.bean.vo.ProductionBomStructureVo">
+ select pbs.*,
+ p.product_name as productName,
+ pm.product_id as productId,
+ pm.model,
+ top1.name as operationName
+ from production_bom_structure pbs
+ left join product_model pm on pbs.product_model_id = pm.id
+ left join product p on pm.product_id = p.id
+ left join technology_operation top1 on pbs.technology_operation_id = top1.id
+ where pbs.production_order_bom_id = #{bomId}
+ order by pbs.id
+ </select>
+
+ <select id="pickByBomId" resultType="com.ruoyi.production.bean.vo.ProductionBomStructureVo">
+ SELECT
+ pbs.*,
+ p.product_name AS productName,
+ pm.product_id AS productId,
+ pm.model,
+ top1.NAME AS operationName
+ FROM
+ production_bom_structure pbs
+ LEFT JOIN product_model pm ON pbs.product_model_id = pm.id
+ LEFT JOIN product p ON pm.product_id = p.id
+ LEFT JOIN technology_operation top1 ON pbs.technology_operation_id = top1.id
+ WHERE
+ pbs.parent_id IS NOT NULL
+ AND pbs.production_order_bom_id = #{bomId}
+ ORDER BY
+ pbs.id
+ </select>
+
</mapper>
--
Gitblit v1.9.3