You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

112 lines
3.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.WxProfitSharingReceiverMapper">
  4. <resultMap id="BaseResultMap" type="com.iformall.domain.po.WxProfitSharingReceiver">
  5. <id column="id" jdbcType="BIGINT" property="id" />
  6. <result column="tenant_id" jdbcType="VARCHAR" property="tenantId" />
  7. <result column="merchant_id" jdbcType="BIGINT" property="merchantId" />
  8. <result column="receiver_type" jdbcType="INTEGER" property="receiverType" />
  9. <result column="receiver_account" jdbcType="VARCHAR" property="receiverAccount" />
  10. <result column="receiver_comments" jdbcType="VARCHAR" property="receiverComments" />
  11. <result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
  12. <result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
  13. <result column="sharing_type" jdbcType="INTEGER" property="sharingType" />
  14. <result column="bank_no" jdbcType="VARCHAR" property="bankNo" />
  15. <result column="true_name" jdbcType="VARCHAR" property="trueName" />
  16. <result column="bank_code" jdbcType="VARCHAR" property="bankCode" />
  17. <result column="status" jdbcType="INTEGER" property="status" />
  18. </resultMap>
  19. <sql id="allColumns">
  20. `id`,`tenant_id`,`merchant_id`,`receiver_type`,`receiver_account`,`receiver_comments`,`create_time`,`update_time`,`sharing_type`,`bank_no`,`true_name`,`bank_code`,`status`
  21. </sql>
  22. <sql id="dynamicWhereConditions">
  23. where 1 = 1
  24. <if test=" null != id ">
  25. and `id` = #{id}
  26. </if>
  27. <if test=" null != tenantId ">
  28. and `tenant_id` = #{tenantId}
  29. </if>
  30. <if test=" null != merchantId ">
  31. and `merchant_id` = #{merchantId}
  32. </if>
  33. <if test=" null != receiverType ">
  34. and `receiver_type` = #{receiverType}
  35. </if>
  36. <if test=" null != receiverAccount ">
  37. and `receiver_account` like concat('%', #{receiverAccount},'%')
  38. </if>
  39. <if test=" null != receiverComments ">
  40. and `receiver_comments` like concat('%', #{receiverComments},'%')
  41. </if>
  42. <if test=" null != createTime ">
  43. and `create_time` = #{createTime}
  44. </if>
  45. <if test=" null != updateTime ">
  46. and `update_time` = #{updateTime}
  47. </if>
  48. <if test=" null != sharingType ">
  49. and `sharing_type` = #{sharingType}
  50. </if>
  51. <if test=" null != bankNo ">
  52. and `bank_no` like concat('%', #{bankNo},'%')
  53. </if>
  54. <if test=" null != trueName ">
  55. and `true_name` like concat('%', #{trueName},'%')
  56. </if>
  57. <if test=" null != bankCode ">
  58. and `bank_code` like concat('%', #{bankCode},'%')
  59. </if>
  60. <if test=" null != status ">
  61. and `status` = #{status}
  62. </if>
  63. <if test=" null != ids ">
  64. and id in
  65. <foreach collection="ids" index="index" item="idItem" open="(" separator="," close=")">
  66. #{idItem}
  67. </foreach>
  68. </if>
  69. <if test=" null != sortColumns"> order by ${sortColumns} </if>
  70. </sql>
  71. <select id="findList" parameterType="com.iformall.domain.po.WxProfitSharingReceiver" resultMap="BaseResultMap">
  72. select <include refid="allColumns" /> from wx_profit_sharing_receiver
  73. <include refid="dynamicWhereConditions" />
  74. </select>
  75. </mapper>