CalculateIndicatorItemInfoMapper.xml 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3. <mapper namespace="com.ims.eval.dao.CalculateIndicatorItemInfoMapper">
  4. <select id="selectList" resultType="com.ims.eval.entity.CalculateIndicatorItemInfo">
  5. SELECT
  6. *
  7. FROM
  8. calculate_indicator_item_info a
  9. <where>
  10. 1=1
  11. <if test="organizationType !=null and organizationType !=''">
  12. and a.organization_type=#{organizationType}
  13. </if>
  14. <if test="checkCycle !=null and checkCycle !=''">
  15. and a.check_cycle=#{checkCycle}
  16. </if>
  17. <if test="year !=null and year !=''">
  18. and a.year=#{year}
  19. </if>
  20. <if test="month !=null and month !=''">
  21. and a.month=#{month}
  22. </if>
  23. <if test="indicatorId !=null and indicatorId !=''">
  24. and a.indicator_id=#{indicatorId}
  25. </if>
  26. <if test="organizationEvaluationId !=null and organizationEvaluationId !=''">
  27. and a.organization_evaluation_id=#{organizationEvaluationId}
  28. </if>
  29. <if test="childCode !=null and childCode !=''">
  30. and a.child_code=#{childCode}
  31. </if>
  32. </where>
  33. </select>
  34. <select id="selectItemInfoByIndicatorIdList" resultType="com.ims.eval.entity.CalculateIndicatorItemInfo">
  35. SELECT
  36. *
  37. FROM
  38. calculate_indicator_item_info a
  39. <where>
  40. <if test="binSection !=null and binSection !=''">
  41. and a.section_id=#{binSection}
  42. </if>
  43. <if test="organizationEvaluationId !=null and organizationEvaluationId !=''">
  44. and a.organization_evaluation_id=#{organizationEvaluationId}
  45. </if>
  46. <if test="indicatorIds !=null">
  47. AND a.indicator_id in
  48. <foreach item="item" collection="indicatorIds" separator="," open="(" close=")" index="">'${item}'</foreach>
  49. </if>
  50. </where>
  51. </select>
  52. </mapper>