From 8a2eaae55660d2618a231242db378c351b53490b Mon Sep 17 00:00:00 2001
From: admin <15939171744@163.com>
Date: 星期三, 16 十月 2024 17:01:54 +0800
Subject: [PATCH] 优化批次信息录入

---
 jcdm-main/src/main/resources/mapper/bs/batchInfo/BsBatchInfoMapper.xml |   17 +++++++++++++++--
 1 files changed, 15 insertions(+), 2 deletions(-)

diff --git a/jcdm-main/src/main/resources/mapper/bs/batchInfo/BsBatchInfoMapper.xml b/jcdm-main/src/main/resources/mapper/bs/batchInfo/BsBatchInfoMapper.xml
index af1643b..8280c88 100644
--- a/jcdm-main/src/main/resources/mapper/bs/batchInfo/BsBatchInfoMapper.xml
+++ b/jcdm-main/src/main/resources/mapper/bs/batchInfo/BsBatchInfoMapper.xml
@@ -15,10 +15,13 @@
         <result property="createUser"    column="create_user"    />
         <result property="updateTime"    column="update_time"    />
         <result property="updateUser"    column="update_user"    />
+        <result property="stationCode"    column="station_code"    />
+        <result property="flag"    column="flag"    />
+
     </resultMap>
 
     <sql id="selectBsBatchInfoVo">
-        select id, material_code, material_name, batch, change_time, remarks, create_time, create_user, update_time, update_user from bs_batch_info
+        select  station_code, flag, id, material_code, material_name, batch, change_time, remarks, create_time, create_user, update_time, update_user from bs_batch_info
     </sql>
 
     <select id="selectBsBatchInfoList" parameterType="BsBatchInfo" resultMap="BsBatchInfoResult">
@@ -27,6 +30,9 @@
             <if test="materialCode != null  and materialCode != ''"> and material_code = #{materialCode}</if>
             <if test="materialName != null  and materialName != ''"> and material_name like concat('%', #{materialName}, '%')</if>
             <if test="batch != null  and batch != ''"> and batch = #{batch}</if>
+            <if test="flag != null  and flag != ''"> and flag = #{flag}</if>
+            <if test="stationCode != null  and stationCode != ''"> and station_code = #{stationCode}</if>
+
         </where>
     </select>
     
@@ -48,7 +54,10 @@
             <if test="createUser != null">create_user,</if>
             <if test="updateTime != null">update_time,</if>
             <if test="updateUser != null">update_user,</if>
-         </trim>
+            <if test="stationCode != null">station_code,</if>
+            <if test="flag != null">flag,</if>
+
+        </trim>
         <trim prefix="values (" suffix=")" suffixOverrides=",">
             <if test="id != null">#{id},</if>
             <if test="materialCode != null">#{materialCode},</if>
@@ -60,6 +69,8 @@
             <if test="createUser != null">#{createUser},</if>
             <if test="updateTime != null">#{updateTime},</if>
             <if test="updateUser != null">#{updateUser},</if>
+            <if test="stationCode != null">#{stationCode},</if>
+            <if test="flag != null">#{flag},</if>
          </trim>
     </insert>
 
@@ -75,6 +86,8 @@
             <if test="createUser != null">create_user = #{createUser},</if>
             <if test="updateTime != null">update_time = #{updateTime},</if>
             <if test="updateUser != null">update_user = #{updateUser},</if>
+            <if test="stationCode != null">station_code = #{stationCode},</if>
+            <if test="flag != null">flag = #{flag},</if>
         </trim>
         where id = #{id}
     </update>

--
Gitblit v1.9.3