<?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.yeejoin.amos.boot.module.hygf.api.mapper.HygfRectificationOrderMapper">

    <select id="selectOrderPage" resultType="com.yeejoin.amos.boot.module.hygf.api.entity.HygfRectificationOrder">
        select
        sequence_nbr,
        peasant_househole_name,
        peasant_househole_code,
        project_address_name,
        peasant_househole_id,
        rectification_idea,
        rectification_file  as rectificationFile,
        result_file  as resultFile,
        rectification_result ,
        audit_idea,
        audit_result,
        rectification_type,
        rectification_source,
        rectification_history,
        rectification_status,
        project_region_manger
        from hygf_rectification_order where
        peasant_househole_id = #{peasantHouseholeId}
    <if test="rectificationSource != null and rectificationSource.size() > 0" >
     and   rectification_source in
        <foreach collection="rectificationSource" separator="," item="item" open="(" close=")" >
            #{item}
        </foreach>
    </if>
    </select>


</mapper>
