From b6b46e1c4d390c80cf9bd7d4daa23202f2d11a22 Mon Sep 17 00:00:00 2001
From: Junjie <fallin.jie@qq.com>
Date: 星期五, 26 五月 2023 13:47:57 +0800
Subject: [PATCH] 站点管理编辑高低库位

---
 src/main/resources/mapper/ViewStockUseMapper.xml |   34 ++++++++++++++++++++++++++++++++++
 1 files changed, 34 insertions(+), 0 deletions(-)

diff --git a/src/main/resources/mapper/ViewStockUseMapper.xml b/src/main/resources/mapper/ViewStockUseMapper.xml
index cc723f6..2362f2e 100644
--- a/src/main/resources/mapper/ViewStockUseMapper.xml
+++ b/src/main/resources/mapper/ViewStockUseMapper.xml
@@ -112,5 +112,39 @@
 			and matnr = #{matnr}
 		</if>
 	</select>
+	<sql id="checkReportCondition">
+		<if test="matnr!=null and matnr!='' ">
+			and matnr like '%' + #{matnr} + '%'
+		</if>
+		<if test="maktx!=null and maktx!='' ">
+			and maktx like '%' + #{maktx} + '%'
+		</if>
+		<if test="specs!=null and specs!='' ">
+			and specs like '%' + #{specs} + '%'
+		</if>
+		<if test="batch!=null and batch!='' ">
+			and batch like '%' + #{batch} + '%'
+		</if>
+		<if test="zpallet!=null and zpallet!='' ">
+			and zpallet like '%' + #{zpallet} + '%'
+		</if>
+		<if test="locNo!=null and locNo!='' ">
+			and locNo like '%' + #{locNo} + '%'
+		</if>
+		<if test="staNo!=null and staNo!='' ">
+			and staNo like '%' + #{staNo} + '%'
+		</if>
+
+	</sql>
+    <select id="selectCheckReport" resultType="com.zy.asrs.entity.result.CheckReport">
+		SELECT  * FROM (
+		SELECT ROW_NUMBER() OVER(Order by appeTime desc ) as row , * FROM asr_check_report WHERE 1 = 1
+		<include refid="checkReportCondition"></include>  ) as a WHERE a.row between #{curr} and #{limit}
+	</select>
+	<select id="selectCheckReportCount" resultType="java.lang.Integer">
+
+		SELECT COUNT(*) FROM asr_check_report WHERE 1 = 1
+		<include refid="checkReportCondition"></include>
+	</select>
 
 </mapper>
\ No newline at end of file

--
Gitblit v1.9.1