From e4fe69941b2dd4582ec0bd82c32b8dfbc30d85b5 Mon Sep 17 00:00:00 2001
From: 廖井涛 <2265517004@qq.com>
Date: 星期四, 22 二月 2024 08:06:43 +0800
Subject: [PATCH] Merge branch 'master' of http://10.153.19.25:10101/r/ERP_override
---
north-glass-erp/src/main/resources/mapper/sd/OrderMapper.xml | 26 +++++++++++++++++---------
1 files changed, 17 insertions(+), 9 deletions(-)
diff --git a/north-glass-erp/src/main/resources/mapper/sd/OrderMapper.xml b/north-glass-erp/src/main/resources/mapper/sd/OrderMapper.xml
index fcf7a2d..0b4cb11 100644
--- a/north-glass-erp/src/main/resources/mapper/sd/OrderMapper.xml
+++ b/north-glass-erp/src/main/resources/mapper/sd/OrderMapper.xml
@@ -33,7 +33,7 @@
*
from
`order` as o
- where o.create_time>=#{startDate} and o.create_time <= #{endDate}
+ where date(o.create_time)>=#{startDate} and date(o.create_time) <= #{endDate}
<if test="orderType!= null and orderType != ''">
and o.create_order = #{orderType}
@@ -44,10 +44,10 @@
</if>
<if test="order.customerId != null and order.customerId != ''">
- and o.customer_id REGEXP #{customerId}
+ and o.customer_id REGEXP #{order.customerId}
</if>
<if test="order.customerName != null and order.customerName != ''">
- and o.customer_name REGEXP #{customerName}
+ and o.customer_name REGEXP #{order.customerName}
</if>
<if test="order.project != null and order.project != ''">
and o.project REGEXP #{order.project}
@@ -60,7 +60,7 @@
</if>
<if test="order.area != null and order.area != ''">
- and o.area REGEXP #{order.area}
+ and o.area REGEXP REGEXP_REPLACE(#{order.area}, '\\.0+$', '')
</if>
<if test="order.createTime != null and order.createTime != ''">
and date(o.create_time) = #{order.createTime}
@@ -97,10 +97,11 @@
<select id="getPageTotal">
select
- CEILING(count(o.id)/#{pageSize})
+ CEILING(count(o.id)/#{pageSize}) as 'pageTotal',
+ count(o.id) as 'total'
from
`order` as o
- where o.create_time>=#{startDate} and o.create_time <= #{endDate}
+ where date (o.create_time)>=#{startDate} and date(o.create_time) <= #{endDate}
<if test="orderType!= null and orderType != ''">
and o.create_order = #{orderType}
</if>
@@ -110,10 +111,10 @@
</if>
<if test="order.customerId != null and order.customerId != ''">
- and o.customer_id REGEXP #{customerId}
+ and o.customer_id REGEXP #{order.customerId}
</if>
<if test="order.customerName != null and order.customerName != ''">
- and o.customer_name REGEXP #{customerName}
+ and o.customer_name REGEXP #{order.customerName}
</if>
<if test="order.project != null and order.project != ''">
and o.project REGEXP #{order.project}
@@ -156,9 +157,16 @@
<if test="order.deliveryAddress != null and order.deliveryAddress != ''">
and o.delivery_address REGEXP #{order.deliveryAddress}
</if>
-
order by o.id desc
limit #{offset},#{pageSize}
</select>
+
+ <update id="reviewOrderById">
+ update `order` set order_review = #{status} where order_id = #{id}
+ </update>
+
+ <update id="reviewProcessById">
+ update `order` set process_review = #{status} where order_id = #{id}
+ </update>
</mapper>
\ No newline at end of file
--
Gitblit v1.8.0