Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.
 
 
 
 
 

54 строки
1.6 KiB

  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.iformall.mapper.WxDataRuleTargetMapper">
  4. <resultMap id="BaseResultMap" type="com.iformall.domain.po.WxDataRuleTarget">
  5. <id column="id" jdbcType="BIGINT" property="id"/>
  6. <result column="tenant_id" jdbcType="VARCHAR" property="tenantId"/>
  7. <result column="parent" jdbcType="BIGINT" property="parent"/>
  8. <result column="name" jdbcType="VARCHAR" property="name"/>
  9. <result column="tag" jdbcType="VARCHAR" property="tag"/>
  10. <result column="create_time" jdbcType="TIMESTAMP" property="createTime"/>
  11. <result column="update_time" jdbcType="TIMESTAMP" property="updateTime"/>
  12. </resultMap>
  13. <sql id="allColumns">
  14. `id`,`parent`,`name`,`tag`,`create_time`,`update_time`
  15. </sql>
  16. <sql id="dynamicWhereConditions">
  17. where 1 = 1
  18. <if test=" null != id ">
  19. and `id` = #{id}
  20. </if>
  21. <if test=" null != tenantId ">
  22. and `tenant_id` = #{tenantId}
  23. </if>
  24. <if test=" null != parent ">
  25. and `parent` = #{parent}
  26. </if>
  27. <if test=" null != name ">
  28. and `name` like concat('%',#{name},'%')
  29. </if>
  30. <if test=" null != ids ">
  31. and id in
  32. <foreach collection="ids" index="index" item="idItem" open="(" separator="," close=")">
  33. #{idItem}
  34. </foreach>
  35. </if>
  36. <if test=" null != sortColumns">order by ${sortColumns}</if>
  37. </sql>
  38. <select id="findList" parameterType="com.iformall.domain.po.WxDataRuleTarget" resultMap="BaseResultMap">
  39. select
  40. <include refid="allColumns"/>
  41. from wx_data_rule_target
  42. <include refid="dynamicWhereConditions"/>
  43. </select>
  44. </mapper>