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

47 строки
2.3 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.WxMsgValidationcodeModelTenantMapper">
  4. <resultMap id="BaseResultMap" type="com.iformall.domain.po.WxMsgValidationcodeModelTenant">
  5. <id column="id" jdbcType="BIGINT" property="id" />
  6. <result column="tenant_id" jdbcType="VARCHAR" property="tenantId" />
  7. <result column="parent_tenant_id" jdbcType="VARCHAR" property="parentTenantId" />
  8. <result column="model_id" jdbcType="BIGINT" property="modelId" />
  9. <result column="signature" jdbcType="VARCHAR" property="signature" />
  10. <result column="content" jdbcType="VARCHAR" property="content" />
  11. <result column="model_code" jdbcType="VARCHAR" property="modelCode" />
  12. <result column="sms_channel" jdbcType="INTEGER" property="smsChannel" />
  13. </resultMap>
  14. <sql id="allColumns">
  15. `id`,`tenant_id`,`parent_tenant_id`,`model_id`,`signature`,`content`,`model_code`,`sms_channel`
  16. </sql>
  17. <sql id="dynamicWhereConditions">
  18. where 1 = 1
  19. <if test=" null != id "> and `id` = #{id} </if>
  20. <if test=" null != tenantId "> and `tenant_id` = #{tenantId} </if>
  21. <if test=" null != modelId "> and `model_id` = #{modelId} </if>
  22. <if test=" null != signature "> and `signature` = #{signature} </if>
  23. <if test=" null != content "> and `content` = #{content} </if>
  24. <if test=" null != modelCode "> and `model_code` = #{modelCode} </if>
  25. <if test=" null != smsChannel "> and `sms_channel` = #{smsChannel} </if>
  26. <if test=" null != ids ">
  27. and id in
  28. <foreach collection="ids" index="index" item="idItem" open="(" separator="," close=")">
  29. #{idItem}
  30. </foreach>
  31. </if>
  32. <if test=" null != sortColumns"> order by ${sortColumns} </if>
  33. </sql>
  34. <select id="findList" parameterType="com.iformall.domain.po.WxMsgValidationcodeModelTenant" resultMap="BaseResultMap">
  35. select <include refid="allColumns" /> from wx_msg_validationcode_model_tenant
  36. <include refid="dynamicWhereConditions" />
  37. </select>
  38. <select id="findByModelId" parameterType="com.iformall.domain.po.WxMsgValidationcodeModelTenant" resultMap="BaseResultMap">
  39. select <include refid="allColumns" /> from wx_msg_validationcode_model_tenant
  40. where `tenant_id` = #{tenantId} and `model_id` = #{modelId} and sms_channel = #{smsChannel}
  41. </select>
  42. </mapper>