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.
 
 
 
 
 

166 lines
7.7 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.WxProfitSharingReceiverApplyMapper">
  4. <resultMap id="BaseResultMap" type="com.iformall.domain.po.WxProfitSharingReceiverApply">
  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="merchant_id" jdbcType="BIGINT" property="merchantId" />
  9. <result column="plat" jdbcType="INTEGER" property="plat" />
  10. <result column="out_request_no" jdbcType="VARCHAR" property="outRequestNo" />
  11. <result column="organization_type" jdbcType="INTEGER" property="organizationType" />
  12. <result column="finance_institution" jdbcType="INTEGER" property="financeInstitution" />
  13. <result column="business_license_info" jdbcType="VARCHAR" property="businessLicenseInfo" />
  14. <result column="certificate_info" jdbcType="VARCHAR" property="certificateInfo" />
  15. <result column="finance_institution_info" jdbcType="VARCHAR" property="financeInstitutionInfo" />
  16. <result column="id_holder_type" jdbcType="INTEGER" property="idHolderType" />
  17. <result column="id_doc_type" jdbcType="INTEGER" property="idDocType" />
  18. <result column="authorize_letter" jdbcType="VARCHAR" property="authorizeLetter" />
  19. <result column="authorize_letter_copy" jdbcType="VARCHAR" property="authorizeLetterCopy" />
  20. <result column="id_card_info" jdbcType="VARCHAR" property="idCardInfo" />
  21. <result column="id_doc_info" jdbcType="VARCHAR" property="idDocInfo" />
  22. <result column="owner" jdbcType="INTEGER" property="owner" />
  23. <result column="ubo_info_list" jdbcType="VARCHAR" property="uboInfoList" />
  24. <result column="account_info" jdbcType="VARCHAR" property="accountInfo" />
  25. <result column="contact_info" jdbcType="VARCHAR" property="contactInfo" />
  26. <result column="sales_scene_info" jdbcType="VARCHAR" property="salesSceneInfo" />
  27. <result column="settlement_info" jdbcType="VARCHAR" property="settlementInfo" />
  28. <result column="merchant_shortname" jdbcType="VARCHAR" property="merchantShortname" />
  29. <result column="service_phone" jdbcType="VARCHAR" property="servicePhone" />
  30. <result column="sales_info" jdbcType="VARCHAR" property="salesInfo" />
  31. <result column="qualifications" jdbcType="VARCHAR" property="qualifications" />
  32. <result column="addition_info" jdbcType="VARCHAR" property="additionInfo" />
  33. <result column="business_addition_pics" jdbcType="VARCHAR" property="businessAdditionPics" />
  34. <result column="business_addition_desc" jdbcType="VARCHAR" property="businessAdditionDesc" />
  35. <result column="applyment_id" jdbcType="VARCHAR" property="applymentId" />
  36. <result column="applyment_state" jdbcType="INTEGER" property="applymentState" />
  37. <result column="applyment_state_desc" jdbcType="VARCHAR" property="applymentStateDesc" />
  38. <result column="sign_state" jdbcType="INTEGER" property="signState" />
  39. <result column="sign_url" jdbcType="VARCHAR" property="signUrl" />
  40. <result column="sub_mchid" jdbcType="VARCHAR" property="subMchid" />
  41. <result column="account_validation" jdbcType="VARCHAR" property="accountValidation" />
  42. <result column="audit_detail" jdbcType="VARCHAR" property="auditDetail" />
  43. <result column="legal_validation_url" jdbcType="VARCHAR" property="legalValidationUrl" />
  44. <result column="legal_validation_qrcode" jdbcType="VARCHAR" property="legalValidationQrcode" />
  45. <result column="verify_result" jdbcType="INTEGER" property="verifyResult" />
  46. <result column="verify_fail_reason" jdbcType="VARCHAR" property="verifyFailReason" />
  47. <result column="status" jdbcType="INTEGER" property="status" />
  48. <result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
  49. <result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
  50. </resultMap>
  51. <sql id="allColumns">
  52. `id`,`tenant_id`,`parent_tenant_id`,`merchant_id`,`plat`,
  53. `out_request_no`,`organization_type`,`finance_institution`,`business_license_info`,`certificate_info`,`finance_institution_info`,
  54. `id_holder_type`,`id_doc_type`,`authorize_letter`,`authorize_letter_copy`,`id_card_info`,`id_doc_info`,
  55. `owner`,`ubo_info_list`,`account_info`,`contact_info`,`sales_scene_info`,`settlement_info`,
  56. `merchant_shortname`,`service_phone`,`sales_info`,`qualifications`,`addition_info`,`business_addition_pics`,`business_addition_desc`,
  57. `applyment_id`,`applyment_state`,`applyment_state_desc`,`sign_state`,`sign_url`,
  58. `sub_mchid`,`account_validation`,`audit_detail`,`legal_validation_url`,`legal_validation_qrcode`,
  59. `verify_result`,`verify_fail_reason`,`status`,`create_time`,`update_time`
  60. </sql>
  61. <sql id="dynamicWhereConditions">
  62. where 1 = 1
  63. <if test=" null != id ">
  64. and `id` = #{id}
  65. </if>
  66. <if test=" null != tenantId and '' != tenantId">
  67. and `tenant_id` = #{tenantId}
  68. </if>
  69. <if test=" null != parentTenantId and '' != parentTenantId">
  70. and `parent_tenant_id` = #{parentTenantId}
  71. </if>
  72. <if test=" null != merchantId ">
  73. and `merchant_id` = #{merchantId}
  74. </if>
  75. <if test=" null != plat ">
  76. and `plat` = #{plat}
  77. </if>
  78. <if test=" null != outRequestNo and '' != outRequestNo">
  79. and `out_request_no` = #{outRequestNo}
  80. </if>
  81. <if test=" null != organizationType ">
  82. and `organization_type` = #{organizationType}
  83. </if>
  84. <if test=" null != applymentId and '' != applymentId ">
  85. and `applyment_id` = #{applymentId}
  86. </if>
  87. <if test=" null != applymentState ">
  88. and `applyment_state` = #{applymentState}
  89. </if>
  90. <if test=" null != signState ">
  91. and `sign_state` = #{signState}
  92. </if>
  93. <if test=" null != verifyResult ">
  94. and `verify_result` = #{verifyResult}
  95. </if>
  96. <if test=" null != status ">
  97. and `status` = #{status}
  98. </if>
  99. <if test=" null != applymentStates ">
  100. and `applyment_state` in
  101. <foreach collection="applymentStates" index="index" item="idItem" open="(" separator="," close=")">
  102. #{idItem}
  103. </foreach>
  104. </if>
  105. <if test=" null != ids ">
  106. and id in
  107. <foreach collection="ids" index="index" item="idItem" open="(" separator="," close=")">
  108. #{idItem}
  109. </foreach>
  110. </if>
  111. <if test=" null != sortColumns"> order by ${sortColumns} </if>
  112. </sql>
  113. <select id="findList" parameterType="com.iformall.domain.po.WxProfitSharingReceiverApply" resultMap="BaseResultMap">
  114. select
  115. <include refid="allColumns"/>
  116. from wx_profit_sharing_receiver_apply
  117. <include refid="dynamicWhereConditions"/>
  118. </select>
  119. <select id="findResultStateById" parameterType="Long" resultMap="BaseResultMap">
  120. select
  121. `id`,`tenant_id`,`parent_tenant_id`,`merchant_id`,`plat`,`out_request_no`,
  122. `applyment_id`,`applyment_state`,`applyment_state_desc`,`sign_state`,`sign_url`,
  123. `sub_mchid`,`account_validation`,`audit_detail`,`legal_validation_url`,`legal_validation_qrcode`,
  124. `verify_result`,`verify_fail_reason`,`status`,`create_time`,`update_time`
  125. from wx_profit_sharing_receiver_apply
  126. where `id` = #{id}
  127. </select>
  128. <select id="findListByApplymentState" parameterType="com.iformall.domain.po.WxProfitSharingReceiverApply" resultMap="BaseResultMap">
  129. select
  130. `id`,`tenant_id`,`parent_tenant_id`,`merchant_id`,`plat`,`out_request_no`,`applyment_id`,`applyment_state`
  131. from wx_profit_sharing_receiver_apply
  132. <include refid="dynamicWhereConditions"/>
  133. </select>
  134. <select id="findListByVerifyResult" parameterType="com.iformall.domain.po.WxProfitSharingReceiverApply" resultMap="BaseResultMap">
  135. select
  136. `id`,`tenant_id`,`parent_tenant_id`,`merchant_id`,`plat`,`out_request_no`,`applyment_id`,`sub_mchid`,`verify_result`
  137. from wx_profit_sharing_receiver_apply
  138. <include refid="dynamicWhereConditions"/>
  139. </select>
  140. </mapper>