feat:通过门店Code 查询存量客户开通基本信息
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
package com.cool.store.dao.wallet;
|
||||
|
||||
import com.cool.store.entity.wallet.OpenBankInfoDO;
|
||||
import com.cool.store.mapper.wallet.OpenBankInfoMapper;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
/**
|
||||
* @Author suzhuhong
|
||||
* @Date 2025/11/20 10:37
|
||||
* @Version 1.0
|
||||
*/
|
||||
@Repository
|
||||
public class OpenBankInfoDAO {
|
||||
|
||||
|
||||
@Resource
|
||||
private OpenBankInfoMapper openBankInfoMapper;
|
||||
|
||||
public int insertSelective(OpenBankInfoDO openBankInfoDO){
|
||||
return openBankInfoMapper.insertSelective(openBankInfoDO);
|
||||
}
|
||||
|
||||
public int updateByStoreCode(OpenBankInfoDO openBankInfoDO){
|
||||
return openBankInfoMapper.updateByStoreCode(openBankInfoDO);
|
||||
}
|
||||
|
||||
public OpenBankInfoDO getOpenBankInfo(String storeCode){
|
||||
return openBankInfoMapper.getOpenBankInfo(storeCode);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
package com.cool.store.dao.wallet;
|
||||
|
||||
import com.cool.store.entity.wallet.TempOpenWalletInfoDO;
|
||||
import com.cool.store.mapper.wallet.TempOpenWalletInfoMapper;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
/**
|
||||
* @Author suzhuhong
|
||||
* @Date 2025/11/20 10:03
|
||||
* @Version 1.0
|
||||
*/
|
||||
@Repository
|
||||
@RequiredArgsConstructor
|
||||
public class TempOpenWalletInfoDAO {
|
||||
|
||||
@Resource
|
||||
private TempOpenWalletInfoMapper tempOpenWalletInfoMapper;
|
||||
|
||||
/**
|
||||
* 根据门店编号查询临时开通钱包信息
|
||||
* @param StoreCode
|
||||
* @return
|
||||
*/
|
||||
public TempOpenWalletInfoDO getTempOpenWalletInfoByStoreCode(String StoreCode) {
|
||||
if (StoreCode == null){
|
||||
return null;
|
||||
}
|
||||
return tempOpenWalletInfoMapper.getTempOpenWalletInfoByStoreCode(StoreCode);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
package com.cool.store.mapper.wallet;
|
||||
|
||||
import com.cool.store.entity.wallet.OpenBankInfoDO;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import tk.mybatis.mapper.common.Mapper;
|
||||
|
||||
public interface OpenBankInfoMapper extends Mapper<OpenBankInfoDO> {
|
||||
|
||||
|
||||
/**
|
||||
* 查询门店开户信息
|
||||
* @param storeCode
|
||||
* @return
|
||||
*/
|
||||
OpenBankInfoDO getOpenBankInfo(@Param("storeCode") String storeCode);
|
||||
|
||||
/**
|
||||
* 根据门店编码更新
|
||||
* @param openBankInfoDO
|
||||
* @return
|
||||
*/
|
||||
Integer updateByStoreCode(@Param("dto") OpenBankInfoDO openBankInfoDO);
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
package com.cool.store.mapper.wallet;
|
||||
|
||||
import com.cool.store.entity.wallet.TempOpenWalletInfoDO;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import tk.mybatis.mapper.common.Mapper;
|
||||
|
||||
public interface TempOpenWalletInfoMapper extends Mapper<TempOpenWalletInfoDO> {
|
||||
|
||||
/**
|
||||
* 根据StoreCode查询临时开放钱包信息
|
||||
* @param StoreCode
|
||||
* @return
|
||||
*/
|
||||
TempOpenWalletInfoDO getTempOpenWalletInfoByStoreCode(@Param("StoreCode") String StoreCode);
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,94 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.cool.store.mapper.wallet.OpenBankInfoMapper">
|
||||
<resultMap id="BaseResultMap" type="com.cool.store.entity.wallet.OpenBankInfoDO">
|
||||
<!--
|
||||
WARNING - @mbg.generated
|
||||
-->
|
||||
<result column="store_code" jdbcType="VARCHAR" property="storeCode" />
|
||||
<result column="signer_name" jdbcType="VARCHAR" property="signerName" />
|
||||
<result column="signer_id_card" jdbcType="VARCHAR" property="signerIdCard" />
|
||||
<result column="signer_phone" jdbcType="VARCHAR" property="signerPhone" />
|
||||
<result column="signer_id_card_front" jdbcType="VARCHAR" property="signerIdCardFront" />
|
||||
<result column="signer_id_card_back" jdbcType="VARCHAR" property="signerIdCardBack" />
|
||||
<result column="business_license_name" jdbcType="VARCHAR" property="businessLicenseName" />
|
||||
<result column="business_license_code" jdbcType="VARCHAR" property="businessLicenseCode" />
|
||||
<result column="business_license_photo" jdbcType="VARCHAR" property="businessLicensePhoto" />
|
||||
<result column="legal_is_signer" jdbcType="TINYINT" property="legalIsSigner" />
|
||||
<result column="legal_name" jdbcType="VARCHAR" property="legalName" />
|
||||
<result column="legal_id_card" jdbcType="VARCHAR" property="legalIdCard" />
|
||||
<result column="legal_phone" jdbcType="VARCHAR" property="legalPhone" />
|
||||
<result column="legal_id_card_front" jdbcType="VARCHAR" property="legalIdCardFront" />
|
||||
<result column="legal_id_card_back" jdbcType="VARCHAR" property="legalIdCardBack" />
|
||||
<result column="settlement_card" jdbcType="VARCHAR" property="settlementCard" />
|
||||
<result column="bank_branch_name" jdbcType="VARCHAR" property="bankBranchName" />
|
||||
<result column="bank_branch_code" jdbcType="VARCHAR" property="bankBranchCode" />
|
||||
<result column="bank_reserved_phone" jdbcType="VARCHAR" property="bankReservedPhone" />
|
||||
</resultMap>
|
||||
|
||||
<select id="getOpenBankInfo" resultMap="BaseResultMap">
|
||||
select * from zxjp_open_bank_info where store_code = #{storeCode}
|
||||
</select>
|
||||
|
||||
<update id="updateByStoreCode" parameterType="com.cool.store.entity.wallet.OpenBankInfoDO">
|
||||
UPDATE zxjp_open_bank_info
|
||||
<set>
|
||||
<if test="dto.signerName != null and dto.signerName != ''">
|
||||
signer_name = #{dto.signerName},
|
||||
</if>
|
||||
<if test="dto.signerIdCard != null and dto.signerIdCard != ''">
|
||||
signer_id_card = #{dto.signerIdCard},
|
||||
</if>
|
||||
<if test="dto.signerPhone != null and dto.signerPhone != ''">
|
||||
signer_phone = #{dto.signerPhone},
|
||||
</if>
|
||||
<if test="dto.signerIdCardFront != null and dto.signerIdCardFront != ''">
|
||||
signer_id_card_front = #{dto.signerIdCardFront},
|
||||
</if>
|
||||
<if test="dto.signerIdCardBack != null and dto.signerIdCardBack != ''">
|
||||
signer_id_card_back = #{dto.signerIdCardBack},
|
||||
</if>
|
||||
<if test="dto.businessLicenseName != null and dto.businessLicenseName != ''">
|
||||
business_license_name = #{dto.businessLicenseName},
|
||||
</if>
|
||||
<if test="dto.businessLicenseCode != null and dto.businessLicenseCode != ''">
|
||||
business_license_code = #{dto.businessLicenseCode},
|
||||
</if>
|
||||
<if test="dto.businessLicensePhoto != null and dto.businessLicensePhoto != ''">
|
||||
business_license_photo = #{dto.businessLicensePhoto},
|
||||
</if>
|
||||
<if test="dto.legalIsSigner != null">
|
||||
legal_is_signer = #{dto.legalIsSigner},
|
||||
</if>
|
||||
<if test="dto.legalName != null and dto.legalName != ''">
|
||||
legal_name = #{dto.legalName},
|
||||
</if>
|
||||
<if test="dto.legalIdCard != null and dto.legalIdCard != ''">
|
||||
legal_id_card = #{dto.legalIdCard},
|
||||
</if>
|
||||
<if test="dto.legalPhone != null and dto.legalPhone != ''">
|
||||
legal_phone = #{dto.legalPhone},
|
||||
</if>
|
||||
<if test="dto.legalIdCardFront != null and dto.legalIdCardFront != ''">
|
||||
legal_id_card_front = #{dto.legalIdCardFront},
|
||||
</if>
|
||||
<if test="dto.legalIdCardBack != null and dto.legalIdCardBack != ''">
|
||||
legal_id_card_back = #{dto.legalIdCardBack},
|
||||
</if>
|
||||
<if test="dto.settlementCard != null and dto.settlementCard != ''">
|
||||
settlement_card = #{dto.settlementCard},
|
||||
</if>
|
||||
<if test="dto.bankBranchName != null and dto.bankBranchName != ''">
|
||||
bank_branch_name = #{dto.bankBranchName},
|
||||
</if>
|
||||
<if test="dto.bankBranchCode != null and dto.bankBranchCode != ''">
|
||||
bank_branch_code = #{dto.bankBranchCode},
|
||||
</if>
|
||||
<if test="dto.bankReservedPhone != null and dto.bankReservedPhone != ''">
|
||||
bank_reserved_phone = #{dto.bankReservedPhone},
|
||||
</if>
|
||||
</set>
|
||||
WHERE store_code = #{dto.storeCode}
|
||||
</update>
|
||||
|
||||
</mapper>
|
||||
@@ -0,0 +1,40 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.cool.store.mapper.wallet.TempOpenWalletInfoMapper">
|
||||
<resultMap id="BaseResultMap" type="com.cool.store.entity.wallet.TempOpenWalletInfoDO">
|
||||
<!--
|
||||
WARNING - @mbg.generated
|
||||
-->
|
||||
<result column="store_code" jdbcType="VARCHAR" property="storeCode" />
|
||||
<result column="store_name" jdbcType="VARCHAR" property="storeName" />
|
||||
<result column="store_mode" jdbcType="VARCHAR" property="storeMode" />
|
||||
<result column="ledger_name" jdbcType="VARCHAR" property="ledgerName" />
|
||||
<result column="ledger_status" jdbcType="VARCHAR" property="ledgerStatus" />
|
||||
<result column="business_type" jdbcType="VARCHAR" property="businessType" />
|
||||
<result column="business_reg_name" jdbcType="VARCHAR" property="businessRegName" />
|
||||
<result column="business_license_no" jdbcType="VARCHAR" property="businessLicenseNo" />
|
||||
<result column="business_address" jdbcType="VARCHAR" property="businessAddress" />
|
||||
<result column="province" jdbcType="VARCHAR" property="province" />
|
||||
<result column="city" jdbcType="VARCHAR" property="city" />
|
||||
<result column="district" jdbcType="VARCHAR" property="district" />
|
||||
<result column="legal_person_name" jdbcType="VARCHAR" property="legalPersonName" />
|
||||
<result column="legal_person_id_no" jdbcType="VARCHAR" property="legalPersonIdNo" />
|
||||
<result column="legal_id_start_date" jdbcType="DATE" property="legalIdStartDate" />
|
||||
<result column="legal_id_expire_date" jdbcType="DATE" property="legalIdExpireDate" />
|
||||
<result column="settler_name" jdbcType="VARCHAR" property="settlerName" />
|
||||
<result column="settler_id_no" jdbcType="VARCHAR" property="settlerIdNo" />
|
||||
<result column="settler_id_start_date" jdbcType="DATE" property="settlerIdStartDate" />
|
||||
<result column="settler_id_expire_date" jdbcType="DATE" property="settlerIdExpireDate" />
|
||||
<result column="bank_branch_name" jdbcType="VARCHAR" property="bankBranchName" />
|
||||
<result column="bank_branch_no" jdbcType="VARCHAR" property="bankBranchNo" />
|
||||
<result column="settlement_card_no" jdbcType="VARCHAR" property="settlementCardNo" />
|
||||
<result column="bank_reserved_phone" jdbcType="VARCHAR" property="bankReservedPhone" />
|
||||
<result column="accounting_relation" jdbcType="VARCHAR" property="accountingRelation" />
|
||||
</resultMap>
|
||||
|
||||
<select id="getTempOpenWalletInfoByStoreCode" resultMap="BaseResultMap">
|
||||
select * from zxjp_temp_open_wallet_info where store_id = #{storeCode}
|
||||
</select>
|
||||
|
||||
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user