From 772ce1ff99b32e0d8c5ee1135f8a9fb03eb9fc60 Mon Sep 17 00:00:00 2001
From: zss <zss@example.com>
Date: 星期二, 15 八月 2023 14:51:13 +0800
Subject: [PATCH] 添加校验

---
 inventory-server/src/main/resources/mapper/SaleMapper.xml |   27 ++++++++++++++-------------
 1 files changed, 14 insertions(+), 13 deletions(-)

diff --git a/inventory-server/src/main/resources/mapper/SaleMapper.xml b/inventory-server/src/main/resources/mapper/SaleMapper.xml
index ef865df..5d95a13 100644
--- a/inventory-server/src/main/resources/mapper/SaleMapper.xml
+++ b/inventory-server/src/main/resources/mapper/SaleMapper.xml
@@ -17,7 +17,7 @@
         <if test="name!=null and name!=''">
             and name LIKE CONCAT('%',#{name},'%')
         </if>
-        <if test="type!=null and type!=''">
+        <if test="type!=null ">
             and type=#{type}
         </if>
         <if test="delTime!=null and delTime!=''">
@@ -29,26 +29,27 @@
     <!--鏌ヨ璁㈠崟BOM鍒楄〃-->
     <select id="selectAllOrder" resultType="java.util.Map">
         select s.id ,
-            order_number,
-            saleman,
-            proname,
-            sm.name,
-            specifications,
-            unit,
-            number,
-            DATE_FORMAT(s.create_time, '%Y-%m-%d') '涓嬪崟鏃ユ湡',
-            DATE_FORMAT(delTime, '%Y-%m-%d') '浜よ揣鏃ユ湡',
-            bianzhi_state
-            from mom_ocean.sale s ,mom_ocean.sale_material sm
+        order_number,
+        saleman,
+        proname,
+        sm.name,
+        specifications,
+        unit,
+        number,
+        DATE_FORMAT(s.create_time, '%Y-%m-%d') '涓嬪崟鏃ユ湡',
+        DATE_FORMAT(delTime, '%Y-%m-%d') '浜よ揣鏃ユ湡',
+        bianzhi_state
+        from mom_ocean.sale s ,mom_ocean.sale_material sm
         where s.id=sm.sale_id
         and s.state=1
+        and bianzhi_state!=2
         <if test="orderCode!=null and orderCode!=''">
             and order_number like concat('%',#{orderCode},'%')
         </if>
         <if test="name!=null and name!=''">
             and sm.name like concat('%',#{name},'%')
         </if>
-        <if test="state!=null and state!=''">
+        <if test="state!=null ">
             and bianzhi_state=#{state}
         </if>
         <if test="time!=null and time!=''">

--
Gitblit v1.9.3