<?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.ruoyi.gysl.mapper.XfcyglMapper">
    <select id="page" resultType="com.ruoyi.gysl.entity.Xfcygl">
        select * from gysl_xfcygl
        <where>
            <if test="req.cylb != null and req.cylb!= ''">
                AND cylb like concat('%',#{req.cylb},'%')
            </if>
            <if test="req.cyxf != null and req.cyxf != '' ">
                AND cyxf like concat('%',#{req.cyxf},'%')
            </if>
            <if test="req.slsyx != null ">
                AND slsyx = #{req.slsyx}
            </if>
            <if test="req.startTime != null">
                AND update_time &gt;= #{req.startTime}  <!-- 大于等于 -->
            </if>
            <if test="req.endTime != null">
                AND update_time &lt;= #{req.endTime}     <!-- 小于等于 -->
            </if>
        </where>
    </select>

</mapper>

