From f9e742b17c47d9f0df3a56caa09f18c8f99aa3f8 Mon Sep 17 00:00:00 2001
From: whycq <123456>
Date: 星期四, 03 七月 2025 17:44:37 +0800
Subject: [PATCH] #
---
src/main/resources/mapper/OrderMapper.xml | 31 +++++++++++++++++++++++++++++++
1 files changed, 31 insertions(+), 0 deletions(-)
diff --git a/src/main/resources/mapper/OrderMapper.xml b/src/main/resources/mapper/OrderMapper.xml
index f422abc..50c9d9f 100644
--- a/src/main/resources/mapper/OrderMapper.xml
+++ b/src/main/resources/mapper/OrderMapper.xml
@@ -42,4 +42,35 @@
</resultMap>
+ <update id="updateSettle">
+ update man_order
+ set settle = #{settle}
+ ,update_time = getdate()
+ <if test="userId != null">
+ ,update_by = #{userId}
+ </if>
+ where 1=1
+ and id = #{orderId}
+ </update>
+ <update id="updateSettleTo1">
+ UPDATE man_order set settle = 1 WHERE order_no = #{orderNo}
+ </update>
+ <select id="checkDetlWorkQtyLess0" resultType="integer">
+ select count(*) FROM man_order_detl WHERE order_no = #{orderNo} and (work_qty > 0 or qty > 0)
+ </select>
+
+ <select id="selectComplete" resultMap="BaseResultMap">
+ select top 5 *
+ from man_order
+ where 1=1
+ and settle = 4
+ and status = 1
+ and doc_type not in(18,19)
+ order by create_time asc
+ </select>
+
+ <insert id="addToLogTable">
+ INSERT INTO man_order_log SELECT * FROM man_order WHERE id = #{id}
+ </insert>
+
</mapper>
--
Gitblit v1.9.1