From 6bbcdd0d1beeca74251f63ea42b9ee8349e97902 Mon Sep 17 00:00:00 2001
From: chenlu <1320612696@qq.com>
Date: 星期二, 15 七月 2025 10:19:54 +0800
Subject: [PATCH] 优化在制品查询速度
---
north-glass-erp/src/main/resources/mapper/sd/DeliveryMapper.xml | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/north-glass-erp/src/main/resources/mapper/sd/DeliveryMapper.xml b/north-glass-erp/src/main/resources/mapper/sd/DeliveryMapper.xml
index 3ca6c8c..4564208 100644
--- a/north-glass-erp/src/main/resources/mapper/sd/DeliveryMapper.xml
+++ b/north-glass-erp/src/main/resources/mapper/sd/DeliveryMapper.xml
@@ -42,7 +42,12 @@
<select id="getmaximum" >
- select count(*) from sd.delivery where date(create_time)=CURDATE()
+ select
+ ifnull(SUBSTR(max(right(delivery_id,8)) from 7),0)
+ from
+ sd.delivery as a
+ where
+ date(a.create_time) = curdate()
</select>
<select id="getmaximumMonth">
@@ -244,7 +249,8 @@
<select id="getSelectShippingOrderDetailPrinting" >
select
d.order_id,d.quantity,round(d.money,0) as money ,d.area,d.project,
- d.customer_id,d.customer_name,d.creator,d.salesman,d.salesman_id
+ d.customer_id,d.customer_name,d.creator,d.salesman,d.salesman_id,
+ d.processing_note,d.contract_id,d.delivery_date
from sd.`order` d
<where>
<if test="orderDetail.orderId != null and orderDetail.orderId != ''">
--
Gitblit v1.8.0