From ab290efb7df666e173fcd88c32f066f333825c5e Mon Sep 17 00:00:00 2001
From: dubin <bindu_bean@163.com>
Date: 星期六, 18 十月 2025 08:50:01 +0800
Subject: [PATCH] 联调
---
src/main/resources/mapper/OrderDetlMapper.xml | 59 +++++++++++++++++++++++++++++++++++------------------------
1 files changed, 35 insertions(+), 24 deletions(-)
diff --git a/src/main/resources/mapper/OrderDetlMapper.xml b/src/main/resources/mapper/OrderDetlMapper.xml
index b5870e9..f7ae4f7 100644
--- a/src/main/resources/mapper/OrderDetlMapper.xml
+++ b/src/main/resources/mapper/OrderDetlMapper.xml
@@ -58,6 +58,7 @@
<result column="ware_id" property="wareId" />
<result column="ware_mame" property="wareName" />
<result column="packing" property="packing" />
+ <result column="det_id" property="detId"/>
</resultMap>
<select id="selectItem" resultMap="BaseResultMap">
@@ -80,9 +81,14 @@
where 1=1
and order_no = #{orderNo}
and matnr = #{matnr}
- <if test="batch!=null and batch!='' ">
- and batch = #{batch}
- </if>
+ <choose>
+ <when test="batch != null and batch != ''">
+ and batch = #{batch}
+ </when>
+ <otherwise>
+ and (batch IS NULL OR batch = '')
+ </otherwise>
+ </choose>
</select>
<select id="selectWorkingDetls" resultMap="BaseResultMap">
@@ -169,6 +175,13 @@
</choose>
</update>
+ <update id="decrease2">
+ update man_order_detl
+ set work_qty = work_qty - #{qty}
+ where 1=1
+ and id = #{id}
+ </update>
+
<update id="modifyStatus">
update man_order_detl
set status = #{status}
@@ -180,36 +193,34 @@
INSERT INTO man_order_detl_log SELECT * FROM man_order_detl WHERE id = #{id}
</insert>
- <update id="increaseQtyByOrderNo">
+<!-- <update id="increaseQtyByOrderNo">-->
+<!-- update man_order_detl-->
+<!-- set qty = qty + #{qty}-->
+<!-- where 1=1-->
+<!-- and order_no = #{orderNo}-->
+<!-- and matnr = #{matnr}-->
+<!-- <choose>-->
+<!-- <when test="batch != null and batch != ''">-->
+<!-- and batch = #{batch}-->
+<!-- </when>-->
+<!-- <otherwise>-->
+<!-- and (batch IS NULL OR batch = '')-->
+<!-- </otherwise>-->
+<!-- </choose>-->
+<!-- </update>-->
+
+ <update id="increaseQtyById">
update man_order_detl
set qty = qty + #{qty}
where 1=1
- and order_no = #{orderNo}
- and matnr = #{matnr}
- <choose>
- <when test="batch != null and batch != ''">
- and batch = #{batch}
- </when>
- <otherwise>
- and (batch IS NULL OR batch = '')
- </otherwise>
- </choose>
+ and id = #{id}
</update>
<update id="increaseWorkQty">
update man_order_detl
set work_qty = work_qty + #{workQty}
where 1=1
- and order_id = #{orderId}
- and matnr = #{matnr}
- <choose>
- <when test="batch != null and batch != ''">
- and batch = #{batch}
- </when>
- <otherwise>
- and (batch IS NULL OR batch = '')
- </otherwise>
- </choose>
+ and id = #{id}
</update>
--
Gitblit v1.9.1