|
@@ -16,9 +16,12 @@ import com.zanxiang.manage.domain.dto.*;
|
|
|
import com.zanxiang.manage.domain.params.UserListParam;
|
|
|
import com.zanxiang.manage.domain.params.UserUpdateParam;
|
|
|
import com.zanxiang.manage.domain.vo.GameUserVO;
|
|
|
+import com.zanxiang.manage.domain.vo.UserCardVO;
|
|
|
import com.zanxiang.manage.domain.vo.UserListVO;
|
|
|
import com.zanxiang.manage.domain.vo.UserVO;
|
|
|
import com.zanxiang.manage.service.*;
|
|
|
+import com.zanxiang.mybatis.entity.PromoAccount;
|
|
|
+import com.zanxiang.mybatis.entity.PromoChannel;
|
|
|
import com.zanxiang.mybatis.entity.User;
|
|
|
import com.zanxiang.mybatis.entity.UserExt;
|
|
|
import com.zanxiang.mybatis.mapper.UserMapper;
|
|
@@ -49,15 +52,15 @@ public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements Us
|
|
|
@Autowired
|
|
|
private GameService gameService;
|
|
|
|
|
|
- @Autowired
|
|
|
- private ChannelService channelService;
|
|
|
-
|
|
|
@Autowired
|
|
|
private GameUserService gameUserService;
|
|
|
|
|
|
@Autowired
|
|
|
private PromoChannelService promoChannelService;
|
|
|
|
|
|
+ @Autowired
|
|
|
+ private PromoAccountService promoAccountService;
|
|
|
+
|
|
|
@Autowired
|
|
|
private UserService userService;
|
|
|
|
|
@@ -68,7 +71,7 @@ public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements Us
|
|
|
private GameCategoryService gameCategoryService;
|
|
|
|
|
|
@Autowired
|
|
|
- private PromoAccountService promoAccountService;
|
|
|
+ private UserCardService userCardService;
|
|
|
|
|
|
/**
|
|
|
* 玩家列表查询
|
|
@@ -248,36 +251,36 @@ public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements Us
|
|
|
throw new BaseException("用户信息不存在!");
|
|
|
}
|
|
|
//查询用户拓展信息
|
|
|
- UserExtDTO userExtDTO = userExtService.getById(userId);
|
|
|
- if (userExtDTO == null) {
|
|
|
- throw new BaseException("用户拓展信息不存在!");
|
|
|
+ UserCardVO userCardVO = userCardService.getByUserId(userId);
|
|
|
+ if (userCardVO == null) {
|
|
|
+ throw new BaseException("用户实名信息不存在!");
|
|
|
}
|
|
|
//拓展信息补充
|
|
|
- userVO.setRealName(userExtDTO.getRealName());
|
|
|
- userVO.setBirthday(userExtDTO.getBirthday());
|
|
|
- userVO.setSex(userExtDTO.getSex());
|
|
|
- userVO.setIdCard(userExtDTO.getIdCard());
|
|
|
- userVO.setRegMobile(userExtDTO.getRegMobile());
|
|
|
- userVO.setRegEmail(userExtDTO.getRegEmail());
|
|
|
- userVO.setRegFrom(userExtDTO.getRegFrom());
|
|
|
- userVO.setRegIp(userExtDTO.getRegIp());
|
|
|
+ userVO.setRealName(userCardVO.getCardName());
|
|
|
+ userVO.setBirthday(userCardVO.getBirthday());
|
|
|
+ userVO.setSex(userCardVO.getSex());
|
|
|
+ userVO.setIdCard(userCardVO.getCardId());
|
|
|
+ userVO.setRegMobile(user.getMobile());
|
|
|
+ userVO.setRegEmail(user.getEmail());
|
|
|
+
|
|
|
+ userVO.setRegIp(user.getIp());
|
|
|
//注册游戏
|
|
|
- GameDTO gameDTO = gameService.getById(userExtDTO.getRegGameId());
|
|
|
+ GameDTO gameDTO = gameService.getById(user.getGameId());
|
|
|
if (gameDTO != null) {
|
|
|
userVO.setRegGame(gameDTO.getName());
|
|
|
}
|
|
|
//渠道
|
|
|
- ChannelDTO channelDTO = channelService.getById(user.getAgentId());
|
|
|
- if (channelDTO != null) {
|
|
|
- userVO.setChannelName(channelDTO.getChannelName());
|
|
|
+ PromoChannel promoChannel = promoChannelService.getById(user.getAgentId());
|
|
|
+ if (promoChannel != null) {
|
|
|
+ userVO.setChannelName(promoChannel.getChannel());
|
|
|
+ PromoAccount promoAccount = promoAccountService.getById(promoChannel.getAccountId());
|
|
|
+ userVO.setRegFrom(promoAccount.getAccount());
|
|
|
}
|
|
|
//vip等级
|
|
|
GameUserVO maxVipGameUser = gameUserService.getMaxVipGameUser(userId);
|
|
|
if (maxVipGameUser != null) {
|
|
|
userVO.setVipMax(maxVipGameUser.getRoleVipMax());
|
|
|
}
|
|
|
- //地址
|
|
|
- userVO.setAddress("贝达梦工厂E座二楼趣程科技");
|
|
|
return userVO;
|
|
|
}
|
|
|
|