From f8a5192aa2797e83f5000ff9035f149b0a1b00a1 Mon Sep 17 00:00:00 2001
From: whycq <913841844@qq.com>
Date: 星期一, 28 十月 2024 15:42:58 +0800
Subject: [PATCH] #更新接口
---
zy-asrs-common/src/main/resources/mapper/wms/LocDetlMapper.xml | 41 +++++++++++++++++++++++++++++++++++++++++
1 files changed, 41 insertions(+), 0 deletions(-)
diff --git a/zy-asrs-common/src/main/resources/mapper/wms/LocDetlMapper.xml b/zy-asrs-common/src/main/resources/mapper/wms/LocDetlMapper.xml
index 1be8aea..36b1b7d 100644
--- a/zy-asrs-common/src/main/resources/mapper/wms/LocDetlMapper.xml
+++ b/zy-asrs-common/src/main/resources/mapper/wms/LocDetlMapper.xml
@@ -23,11 +23,17 @@
<if test="map.maktx!=null and map.maktx!='' ">
and a.maktx like '%' + #{map.maktx} + '%'
</if>
+ <if test="map.zpallet!=null and map.zpallet!='' ">
+ and a.zpallet like '%' + #{map.zpallet} + '%'
+ </if>
<if test="map.batch!=null and map.batch!='' ">
and a.batch like '%' + #{map.batch} + '%'
</if>
<if test="map.anfme!=null and map.anfme!='' ">
and a.anfme like '%' + #{map.anfme} + '%'
+ </if>
+ <if test="map.owner!=null and map.owner!='' ">
+ and a.owner like '%' + #{map.owner} + '%'
</if>
<if test="map.startTime!=null and map.endTime!=null">
and a.modi_time between #{map.startTime} and #{map.endTime}
@@ -117,4 +123,39 @@
group by matnr,batch
</select>
+ <select id="selectSameDetl" resultType="java.lang.String">
+ SELECT
+ ld.loc_no
+ FROM wms_loc_detl ld
+ LEFT JOIN common_loc_mast lm ON ld.loc_no = lm.loc_no and ld.host_id = lm.host_id
+ LEFT JOIN (
+ select
+ loc_no,
+ count(1) as count
+ from wms_loc_detl
+ where 1=1
+ and host_id = #{hostId}
+ group by loc_no
+ ) dual on dual.loc_no = lm.loc_no
+ WHERE 1 = 1
+ AND ld.matnr = #{matnr}
+ <if test="batch">
+ AND ld.batch = #{batch}
+ </if>
+ AND (lm.loc_sts = 'F')
+ AND dual.count = 1
+ AND lm.host_id = #{hostId}
+ ORDER BY lm.modi_time ASC
+ </select>
+
+ <select id="getStockStatisExcel" resultType="com.zy.asrs.common.wms.entity.LocDetl">
+ select
+ ROW_NUMBER() over (order by sum(a.anfme) desc) as row
+ , a.matnr
+ , sum(a.anfme) as anfme
+ from wms_loc_detl a
+ where 1=1
+ group by a.matnr
+ </select>
+
</mapper>
--
Gitblit v1.9.1