<?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.gyee.wisdom.alarm.sharding.mapper.WindTurbineTestingPointDiMapper">

    <select id="getWindTurbineTestingPointDi" parameterType="java.util.Map" resultType="com.gyee.wisdom.alarm.sharding.entity.WindTurbineTestingPointDi">
        select * from  windturbinetestingpointdi a
        <where>
            1=1
            <if test="wtId !=null and wtId !=''">
                and a.windturbineid = #{wtId}
            </if>
            <if test="unicode !=null and unicode !=''">
                and a.code = #{unicode}
            </if>
        </where>
    </select>
    <select id="getPointList" parameterType="java.util.Map" resultType="com.gyee.wisdom.alarm.sharding.entity.WindTurbineTestingPointDi">
        select * from  windturbinetestingpointdi a
        <where>
            1=1
            <if test="uniformCodeList  !=null and uniformCodeList.size > 0 ">
                and a.uniformcode in
                <foreach collection="uniformCodeList" item="uniformcode" index="index" open="(" close=")" separator=",">
                    #{uniformcode}
                </foreach>
            </if>
            <if test="windturbineId !=null and windturbineId !=''">
                and a.windturbineid = #{windturbineId}
            </if>
        </where>
    </select>

</mapper>
