LongYanSpareAddMapper.xml 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  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.platform.dao.mapper.spareAdd.LongYanSpareAddMapper">
  4. <sql id="Base_Column_List">
  5. menu.id,
  6. menu.category,
  7. menu.big_category,
  8. menu.name,
  9. menu.ggxh,
  10. menu.unit,
  11. menu.remark,
  12. menu.status,
  13. menu.created_user_id,
  14. menu.created_user_name,
  15. menu.created_time,
  16. menu.update_user_id,
  17. menu.update_user_name,
  18. menu.update_time
  19. </sql>
  20. <sql id="Ref_Column_List">
  21. menu.category,
  22. menu.big_category,
  23. menu.name,
  24. menu.ggxh,
  25. menu.unit,
  26. menu.remark,
  27. menu.status,
  28. </sql>
  29. <sql id="List_Condition">
  30. <if test="id != null and id != ''">
  31. and menu.id = #{id}
  32. </if>
  33. <if test="category != null and category != ''">
  34. and menu.category = #{category}
  35. </if>
  36. <if test="bigCategory != null and bigCategory != ''">
  37. and menu.big_category = #{bigCategory}
  38. </if>
  39. <if test="name != null and name != ''">
  40. and menu.name = #{name}
  41. </if>
  42. <if test="ggxh != null and ggxh != ''">
  43. and menu.ggxh = #{ggxh}
  44. </if>
  45. <if test="unit != null and unit != ''">
  46. and menu.unit = #{unit}
  47. </if>
  48. <if test="remark != null and remark != ''">
  49. and menu.remark = #{remark}
  50. </if>
  51. <if test="status != null">
  52. and menu.status = #{status}
  53. </if>
  54. <if test="createdUserId != null and createdUserId != ''">
  55. and menu.created_user_id = #{createdUserId}
  56. </if>
  57. <if test="createdUserName != null and createdUserName != ''">
  58. and menu.created_user_name = #{createdUserName}
  59. </if>
  60. <if test="createdTimeStart != null">
  61. and menu.created_time <![CDATA[>=]]>; #{createdTimeStart}
  62. </if>
  63. <if test="createdTimeEnd != null">
  64. and menu.created_time <![CDATA[<=]]> #{createdTimeEnd}
  65. </if>
  66. <if test="createdTime != null">
  67. and menu.created_time = #{createdTime}
  68. </if>
  69. <if test="updateUserId != null and updateUserId != ''">
  70. and menu.update_user_id = #{updateUserId}
  71. </if>
  72. <if test="updateUserName != null and updateUserName != ''">
  73. and menu.update_user_name = #{updateUserName}
  74. </if>
  75. <if test="updateTimeStart != null">
  76. and menu.update_time <![CDATA[>=]]>; #{updateTimeStart}
  77. </if>
  78. <if test="updateTimeEnd != null">
  79. and menu.update_time <![CDATA[<=]]> #{updateTimeEnd}
  80. </if>
  81. <if test="updateTime != null">
  82. and menu.update_time = #{updateTime}
  83. </if>
  84. <if test="keyword != null and keyword != ''">
  85. and menu.id like concat(concat('%',#{keyword}),'%')
  86. </if>
  87. </sql>
  88. <select id="selectList" parameterType="com.platform.dao.dto.spareAdd.LongYanSpareAddDTO"
  89. resultType="com.platform.dao.vo.query.spareAdd.LongYanSpareAddVO">
  90. select menu.*
  91. from t_long_yan_spare_add as menu
  92. <where>
  93. <include refid="List_Condition"/>
  94. </where>
  95. </select>
  96. </mapper>