From 0bc7e73b3fc23c115b7f2010a0018c42bd403b1a Mon Sep 17 00:00:00 2001
From: chenlu <1320612696@qq.com>
Date: 星期三, 09 七月 2025 11:19:20 +0800
Subject: [PATCH] 流程卡打印按落架顺序倒序查询
---
north-glass-erp/src/main/resources/mapper/sd/OrderProcessDetailMapper.xml | 14 ++++++++++----
1 files changed, 10 insertions(+), 4 deletions(-)
diff --git a/north-glass-erp/src/main/resources/mapper/sd/OrderProcessDetailMapper.xml b/north-glass-erp/src/main/resources/mapper/sd/OrderProcessDetailMapper.xml
index 30f80d8..c3588ee 100644
--- a/north-glass-erp/src/main/resources/mapper/sd/OrderProcessDetailMapper.xml
+++ b/north-glass-erp/src/main/resources/mapper/sd/OrderProcessDetailMapper.xml
@@ -157,20 +157,23 @@
(select id,process from sd.order_process_detail
where process_id=#{processId}
and technology_number=#{technologyNumber}
+ and order_number=#{orderNumber}
and process=#{thisProcess}
group by process) as b
where a.id = b.id + 1
and a.process_id=#{processId}
+ and a.order_number=#{orderNumber}
and a.technology_number=#{technologyNumber}
</select>
<select id="selectShiftQuantitySv">
- select CAST(concat(b.order_id,'/',a.order_number,'/',a.technology_number) as char ) as 'order_id',
+ select * from(select CAST(concat(b.order_id,'/',a.order_number,'/',a.technology_number) as char ) as 'order_id',
c.child_width,
c.child_height,
a.completed_quantity,
- a.breakage_quantity
+ a.breakage_quantity,
+ a.order_number
from pp.reporting_work as b
left join pp.reporting_work_detail as a
on a.reporting_work_id = b.reporting_work_id
@@ -180,7 +183,10 @@
and c.technology_number = a.technology_number
where b.reviewed_state >=0
and b.creator_id = #{creatorId}
- and UNIX_TIMESTAMP(b.reporting_work_time) BETWEEN UNIX_TIMESTAMP(#{startDate}) and UNIX_TIMESTAMP(#{endDate})
- order by b.id desc
+ and UNIX_TIMESTAMP(b.reporting_work_time) BETWEEN UNIX_TIMESTAMP(#{startDatetime}) and UNIX_TIMESTAMP(#{endDatetime})
+ order by b.id desc ) as e
+ <if test="step != null and step != ''">
+ group by e.order_number
+ </if>
</select>
</mapper>
\ No newline at end of file
--
Gitblit v1.8.0