<?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.ucp.mapper.TurbineInfoMapper">
    <select id="getByInfo" resultType="java.util.LinkedHashMap">
        select * from ${tableName}
        <where>
            <choose>
                <when test="turbineId != null and turbineId !=''">
                    and windturbine_id = #{turbineId}
                </when>
                <when test="lineId != null and lineId !=''">
                    and line_id = #{lineId}
                </when>
                <when test="projectId != null and projectId !=''">
                    and project_id = #{projectId}
                </when>
                <when test="stationId != null and stationId !=''">
                    and windpowerstation_id = #{stationId}
                </when>
            </choose>
            <if test="uniformCode != null and uniformCode !=''">
                and uniform_code=#{uniformCode}
            </if>
        </where>
    </select>
</mapper>