智慧农业后台管理
Administrator
2022-05-19 84b2e543d0acffa9afede334e65ae9b5bde1888c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
<?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="org.springblade.modules.recovery.mapper.RecoveryMapper">
 
    <!--自定义查询采收记录分页数据-->
    <select id="selectRecoveryPage" resultType="org.springblade.modules.recovery.vo.RecoveryVO">
        select sr.*,sl.land_name landName from sys_recovery sr
        left join sys_land sl on sl.id = sr.land_id
        where 1=1
        <if test="recovery.strainId!=null and recovery.strainId!=''">
            and sr.strain_id = #{recovery.strainId}
        </if>
        <if test="recovery.leaves!=null and recovery.leaves!=''">
            and sr.leaves = #{recovery.leaves}
        </if>
        <if test="recovery.landId!=null and recovery.landId!=''">
            and sr.land_id = #{recovery.landId}
        </if>
        <if test="recovery.jobWay!=null and recovery.jobWay!=''">
            and sr.job_way = #{recovery.jobWay}
        </if>
        <if test="recovery.operator!=null and recovery.operator!=''">
            and sr.operator = #{recovery.operator}
        </if>
    </select>
</mapper>