托盘条码下拉框选择
This commit is contained in:
@@ -7,6 +7,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<resultMap type="BasTraycode" id="BasTraycodeResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="formatId" column="format_id" />
|
||||
<result property="formatName" column="format_name" />
|
||||
<result property="trayCode" column="tray_code" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
@@ -16,17 +17,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectBasTraycodeVo">
|
||||
select id, format_id, tray_code, create_time, update_time, spare1, spare2, spare3 from bas_traycode
|
||||
select bt.id, bt.format_id, bt.tray_code, bt.create_time, bt.update_time, bt.spare1, bt.spare2, bt.spare3,btf.remarks as format_name
|
||||
from bas_traycode bt
|
||||
left join bas_traycode_format btf on btf.id = bt.format_id
|
||||
|
||||
</sql>
|
||||
|
||||
<select id="selectBasTraycodeList" parameterType="BasTraycode" resultMap="BasTraycodeResult">
|
||||
<include refid="selectBasTraycodeVo"/>
|
||||
<where>
|
||||
<if test="formatId != null "> and format_id = #{formatId}</if>
|
||||
<if test="trayCode != null and trayCode != ''"> and tray_code = #{trayCode}</if>
|
||||
<if test="spare1 != null and spare1 != ''"> and spare1 = #{spare1}</if>
|
||||
<if test="spare2 != null and spare2 != ''"> and spare2 = #{spare2}</if>
|
||||
<if test="spare3 != null and spare3 != ''"> and spare3 = #{spare3}</if>
|
||||
<if test="formatId != null "> and bt.format_id = #{formatId}</if>
|
||||
<if test="trayCode != null and trayCode != ''"> and bt.tray_code = #{trayCode}</if>
|
||||
<if test="spare1 != null and spare1 != ''"> and bt.spare1 = #{spare1}</if>
|
||||
<if test="spare2 != null and spare2 != ''"> and bt.spare2 = #{spare2}</if>
|
||||
<if test="spare3 != null and spare3 != ''"> and bt.spare3 = #{spare3}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user