From 069a8bfdac267391a9fd6b481da11d04ec0ee16f Mon Sep 17 00:00:00 2001
From: Helius <wangdoubleone@gmail.com>
Date: Sun, 31 May 2020 14:42:49 +0800
Subject: [PATCH] modify regist interface

---
 src/main/java/com/xcong/excoin/modules/member/service/impl/MemberServiceImpl.java |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/src/main/java/com/xcong/excoin/modules/member/service/impl/MemberServiceImpl.java b/src/main/java/com/xcong/excoin/modules/member/service/impl/MemberServiceImpl.java
index 8477168..1d746f9 100644
--- a/src/main/java/com/xcong/excoin/modules/member/service/impl/MemberServiceImpl.java
+++ b/src/main/java/com/xcong/excoin/modules/member/service/impl/MemberServiceImpl.java
@@ -33,6 +33,7 @@
 import com.xcong.excoin.modules.member.parameter.vo.MemberPaymethodDetailVo;
 import com.xcong.excoin.modules.member.service.MemberService;
 import com.xcong.excoin.modules.platform.dao.PlatformSymbolsCoinDao;
+import com.xcong.excoin.modules.platform.entity.PlatformSymbolsCoinEntity;
 import com.xcong.excoin.utils.MessageSourceUtils;
 import com.xcong.excoin.utils.RedisUtils;
 import com.xcong.excoin.utils.ShareCodeUtil;
@@ -43,6 +44,7 @@
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 
+import java.math.BigDecimal;
 import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.List;
@@ -156,6 +158,14 @@
         walletContract.setBorrowedFund(AppContants.INIT_MONEY);
         walletContract.setWalletCode(CoinTypeEnum.USDT.name());
         memberWalletContractDao.insert(walletContract);
+
+        MemberWalletContractSimulateEntity walletContractSimulate = new MemberWalletContractSimulateEntity();
+        walletContractSimulate.setMemberId(member.getId());
+		walletContractSimulate.setAvailableBalance(new BigDecimal(AppContants.INIT_SIMULATE_MONEY));
+		walletContractSimulate.setTotalBalance(new BigDecimal(AppContants.INIT_SIMULATE_MONEY));
+		walletContractSimulate.setFrozenBalance(AppContants.INIT_MONEY);
+		walletContractSimulate.setBorrowedFund(AppContants.INIT_MONEY);
+		walletContractSimulate.setWalletCode(CoinTypeEnum.USDT.name());
 
 
         // 初始化币币钱包
@@ -635,12 +645,15 @@
 		Long symbolscoinId = memberAddCoinAddressDto. getSymbolscoinId();
 		String remark = memberAddCoinAddressDto.getRemark();
 		
+		PlatformSymbolsCoinEntity platformSymbolsCoinEntity = platformSymbolsCoinDao.selectById(symbolscoinId);
+		
 		MemberCoinAddressEntity memberCoinAddressEntity = new MemberCoinAddressEntity();
 		memberCoinAddressEntity.setAddress(address);
 		memberCoinAddressEntity.setMemberId(memberId);
 		memberCoinAddressEntity.setIsBiyict(isBiyict);
 		memberCoinAddressEntity.setSymbolscoinId(symbolscoinId);
 		memberCoinAddressEntity.setLabel(remark);
+		memberCoinAddressEntity.setSymbol(platformSymbolsCoinEntity.getName());
 		
 		memberCoinAddressDao.insert(memberCoinAddressEntity);
 		

--
Gitblit v1.9.1