31 lines
1.1 KiB
XML
31 lines
1.1 KiB
XML
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
||
|
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||
|
|
<mapper namespace="com.zf.foodpurchase.fdsafe.mapper.FoodSpecMapper">
|
||
|
|
|
||
|
|
<!-- 通用查询结果列 -->
|
||
|
|
<sql id="Base_Column_List">
|
||
|
|
spec_id, spec_label, del_flag, create_time, update_time,status
|
||
|
|
</sql>
|
||
|
|
<select id="queryFoodSpecVO" resultType="com.zf.foodpurchase.fdsafe.vo.FoodSpecVO"
|
||
|
|
parameterType="com.zf.foodpurchase.fdsafe.vo.FoodSpecVO">
|
||
|
|
select
|
||
|
|
<include refid="Base_Column_List"/>
|
||
|
|
from food_spec
|
||
|
|
<where>
|
||
|
|
<if test="specId != null and specId != ''">
|
||
|
|
and spec_id = #{specId}
|
||
|
|
</if>
|
||
|
|
<if test="specLabel != null and specLabel != ''">
|
||
|
|
and spec_label like concat('%',#{specLabel},'%')
|
||
|
|
</if>
|
||
|
|
<if test="delFlag != null">
|
||
|
|
and del_flag = #{delFlag}
|
||
|
|
</if>
|
||
|
|
<if test="status != null">
|
||
|
|
and status = #{status}
|
||
|
|
</if>
|
||
|
|
</where>
|
||
|
|
</select>
|
||
|
|
|
||
|
|
</mapper>
|