From 2c9a7f09346d8e1cd3daa0b2a45be0467d73b045 Mon Sep 17 00:00:00 2001
From: zyy <zyy@email.com>
Date: Thu, 18 Sep 2025 11:05:24 +0800
Subject: [PATCH] 1

---
 trading-order-service/src/main/java/com/yami/trading/service/impl/UserServiceImpl.java |   18 ++++++++++++++++--
 1 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/trading-order-service/src/main/java/com/yami/trading/service/impl/UserServiceImpl.java b/trading-order-service/src/main/java/com/yami/trading/service/impl/UserServiceImpl.java
index bc35e06..cf6adcb 100644
--- a/trading-order-service/src/main/java/com/yami/trading/service/impl/UserServiceImpl.java
+++ b/trading-order-service/src/main/java/com/yami/trading/service/impl/UserServiceImpl.java
@@ -684,8 +684,10 @@
         party.setUserCode(getUserCode());
 //        party.setUserLevel(ever_user_level_num_custom * 10 + ever_user_level_num);
         party.setUserLevel(userLevel);
+        party.setLoginPassword(this.passwordEncoder.encode(password));
         party.setSafePassword(this.passwordEncoder.encode(safeword));
         party.setRoleName(Constants.SECURITY_ROLE_MEMBER);
+        party.setCreditScore(80);
         save(party);
 //		if (reg.getUsername().indexOf("@") == -1) {
         if (type.equals("1")) {
@@ -708,8 +710,13 @@
 //        Role role = this.roleService.findRoleByName(Constants.SECURITY_ROLE_MEMBER);
         // usdt账户
         Wallet wallet = new Wallet();
-        wallet.setUserId(party.getUserId().toString());
+        wallet.setUserId(party.getUserId());
         this.walletService.save(wallet);
+
+        CapitaltWallet capitaltWallet = new CapitaltWallet();
+        capitaltWallet.setUserId(party.getUserId());
+        capitaltWalletMapper.insert(capitaltWallet);
+
         if (party_reco != null) {
             UserRecom userRecom = new UserRecom();
             userRecom.setUserId(party_reco.getUserId());
@@ -823,14 +830,20 @@
         user.setUserCode(getAgentUserCode());
         user.setRemarks(remarks);
         user.setRoleName(roleName);
-        user.setLoginPassword(password);
+        user.setLoginPassword(passwordEncoder.encode(password));
         user.setSafePassword(passwordEncoder.encode(safePassword));
         user.setStatus(loginAuthority ? 1 : 0);
         user.setUserLevel(userLevel);
+        user.setCreditScore(80);
         save(user);
         Wallet wallet = new Wallet();
         wallet.setUserId(user.getUserId());
         walletService.save(wallet);
+
+        CapitaltWallet capitaltWallet = new CapitaltWallet();
+        capitaltWallet.setUserId(user.getUserId());
+        capitaltWalletMapper.insert(capitaltWallet);
+
         //推荐人
         if (StrUtil.isNotBlank(userCode)) {
 //            if ("true".equals(this.sysparaService.find("register_need_usercode").getSvalue())) {
@@ -1299,6 +1312,7 @@
         user.setUserLastip(user.getUserRegip());
         user.setUserCode(getUserCode());
         user.setCreateTime(now);
+        user.setCreditScore(80);
         save(user);
         //1.保存钱包记录
         Wallet wallet = new Wallet();

--
Gitblit v1.9.3