From f2728ef322de546ef885e21ea99183bfc7b18f24 Mon Sep 17 00:00:00 2001
From: 陶杰 <1378534974@qq.com>
Date: 星期一, 09 十二月 2024 18:08:06 +0800
Subject: [PATCH] 1.payment_time > 17:00:00 为第二天

---
 src/main/resources/mapper/payment/OrderMapper.xml |   15 +++++++++------
 1 files changed, 9 insertions(+), 6 deletions(-)

diff --git a/src/main/resources/mapper/payment/OrderMapper.xml b/src/main/resources/mapper/payment/OrderMapper.xml
index 4f847ac..f7d5ee9 100644
--- a/src/main/resources/mapper/payment/OrderMapper.xml
+++ b/src/main/resources/mapper/payment/OrderMapper.xml
@@ -52,7 +52,7 @@
             AND q.payment_time &gt;= #{condition.createStartDate}
         </if>
         <if test="condition.createEndDate != null">
-            AND q.payment_time &lt;= #{condition.createEndDate}
+            AND q.payment_time &lt; #{condition.createEndDate}
         </if>
         <if test="condition.partnerId != null">
             AND q.partner_id = #{condition.partnerId}
@@ -132,7 +132,7 @@
             AND q.payment_time  &gt;= #{condition.createStartDate}
         </if>
         <if test="condition.createEndDate != null">
-            AND q.payment_time &lt;= #{condition.createEndDate}
+            AND q.payment_time &lt; #{condition.createEndDate}
         </if>
         <if test="condition.partnerId != null">
             AND q.partner_id = #{condition.partnerId}
@@ -161,6 +161,9 @@
         </if>
         <if test="condition.warehouseLocationCode != null and condition.warehouseLocationCode != ''">
             AND q.warehouse_location_code LIKE concat('%', #{condition.warehouseLocationCode},'%')
+        </if>
+        <if test="condition.createName != null and condition.createName != ''">
+            AND u.nick_name LIKE concat('%', #{condition.createName},'%')
         </if>
 
         ORDER BY q.create_time desc, q.payment_time desc
@@ -194,7 +197,7 @@
             AND q.payment_time &gt;= #{condition.createStartDate}
         </if>
         <if test="condition.createEndDate != null">
-            AND q.payment_time &lt;= #{condition.createEndDate}
+            AND q.payment_time &lt; #{condition.createEndDate}
         </if>
 <!--        <if test="condition.createStartDate != null">-->
 <!--            AND q.create_time &gt;= #{condition.createStartDate}-->
@@ -332,7 +335,7 @@
             AND q.payment_time &gt;= #{condition.startDate}
         </if>
         <if test="condition.endDate != null">
-            AND q.payment_time &lt;= #{condition.endDate}
+            AND q.payment_time &lt; #{condition.endDate}
         </if>
         <if test="condition.createStartDate != null">
             AND q.create_time &gt;= #{condition.createStartDate}
@@ -374,8 +377,8 @@
     <select id="getOrderSaleAmount" resultType="java.math.BigDecimal">
         SELECT sum(o.payment_amount)
         FROM t_order o
-        WHERE o.payment_time is not null
-        and o.refund_time is null
+        WHERE o.deleted=0
+        and o.status_backend not in ('PENDING','CANCEL','REFUND')
         <if test="startTime != null">
             and o.create_time &gt; #{startTime}
         </if>

--
Gitblit v1.9.3