From 13c8b105a7ddf7ac43fbbdea93946f389cd032e9 Mon Sep 17 00:00:00 2001
From: zss <zss@example.com>
Date: 星期一, 28 八月 2023 18:00:13 +0800
Subject: [PATCH] 工艺路线+技术指标

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

diff --git a/inventory-server/src/main/resources/mapper/ConsignmentMapper.xml b/inventory-server/src/main/resources/mapper/ConsignmentMapper.xml
index ccc21e2..1724dbe 100644
--- a/inventory-server/src/main/resources/mapper/ConsignmentMapper.xml
+++ b/inventory-server/src/main/resources/mapper/ConsignmentMapper.xml
@@ -2,6 +2,32 @@
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
 <mapper namespace="com.yuanchu.mom.mapper.ConsignmentMapper">
     <select id="selectAll" resultType="com.yuanchu.mom.pojo.Consignment">
-        select * from mom_ocean.consignment where state=1
+        select *
+        from mom_ocean.consignment
+        where state = 1
+    </select>
+    <select id="selectAllCon" resultType="java.util.Map">
+        select id,
+               name,
+               specifications,
+               quality_traceability,
+               customer_code,
+               unit,
+               number,
+               check_name,
+               fit_name,
+               user_name
+        from mom_ocean.consignment
+        where state=1
+        <if test="name!=null and name!=''">
+            and name like concat('%',#{name},'%')
+        </if>
+        <if test="specifications!=null and specifications!=''">
+            and specifications like concat('%',#{specifications},'%')
+        </if>
+        <if test="time!=null and time!=''">
+            and DATE_FORMAT(create_time, '%Y-%m-%d')=#{time}
+        </if>
+        order by id desc
     </select>
 </mapper>
\ No newline at end of file

--
Gitblit v1.9.3