CwUspTsPeriodDataMapper.xml 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <!DOCTYPE mapper
  3. PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
  4. "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  5. <mapper namespace="com.ruoyi.predict.mapper.CwUspTsPeriodDataMapper">
  6. <resultMap type="CwUspTsPeriodData" id="CwUspTsPeriodDataResult">
  7. <result property="wfPrCwireNo" column="wf_pr_cwire_no"/>
  8. <result property="modelNo" column="model_no"/>
  9. <result property="timeScale" column="time_scale"/>
  10. <result property="dataTime" column="data_time"/>
  11. <result property="windSpeed" column="wind_speed"/>
  12. <result property="modCoeff" column="mod_coeff"/>
  13. <result property="power" column="power"/>
  14. <result property="modPower" column="mod_power"/>
  15. <result property="dataFlag" column="data_flag"/>
  16. </resultMap>
  17. <sql id="selectCwUspTsPeriodDataVo">
  18. select wf_pr_cwire_no, model_no, time_scale, data_time, wind_speed, mod_coeff, power, mod_power, data_flag from cw_usp_ts_period_data
  19. </sql>
  20. <select id="selectCwUspTsPeriodDataList" parameterType="CwUspTsPeriodData" resultMap="CwUspTsPeriodDataResult">
  21. <include refid="selectCwUspTsPeriodDataVo"/>
  22. <where>
  23. <if test="wfPrCwireNo != null ">and wf_pr_cwire_no = #{wfPrCwireNo}</if>
  24. <if test="modelNo != null ">and model_no = #{modelNo}</if>
  25. <if test="timeScale != null ">and time_scale = #{timeScale}</if>
  26. <if test="windSpeed != null ">and wind_speed = #{windSpeed}</if>
  27. <if test="modCoeff != null ">and mod_coeff = #{modCoeff}</if>
  28. <if test="power != null ">and power = #{power}</if>
  29. <if test="modPower != null ">and mod_power = #{modPower}</if>
  30. <if test="dataFlag != null ">and data_flag = #{dataFlag}</if>
  31. <if test="params.beginDataTime != null and params.beginDataTime != '' and params.endDataTime != null and params.endDataTime != ''">
  32. and data_time between to_date(#{params.beginDataTime},'yyyy-MM-dd HH24:MI:SS') and
  33. to_date(#{params.endDataTime},'yyyy-MM-dd HH24:MI:SS')
  34. </if>
  35. <if test="dataTime != null ">and data_time = #{dataTime}</if>
  36. </where>
  37. </select>
  38. <select id="selectCwUspTsPeriodDataById" parameterType="Long" resultMap="CwUspTsPeriodDataResult">
  39. <include refid="selectCwUspTsPeriodDataVo"/>
  40. where wf_pr_cwire_no = #{wfPrCwireNo}
  41. </select>
  42. </mapper>