Forráskód Böngészése

feat : 用户表新增字段

bilingfeng 2 éve
szülő
commit
bf6f2b0754

+ 161 - 0
game-module/game-manage/src/main/java/com/zanxiang/manage/domain/params/UserListParam.java

@@ -0,0 +1,161 @@
+package com.zanxiang.manage.domain.params;
+
+import com.zanxiang.common.base.BasePage;
+import com.zanxiang.mybatis.entity.User;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+import java.time.LocalDate;
+
+/**
+ * @author : lingfeng
+ * @time : 2022-07-06
+ * @description : 玩家列表查询参数
+ */
+@ApiModel
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class UserListParam extends BasePage<User> {
+
+    /**
+     * 玩家id
+     */
+    @ApiModelProperty(notes = "玩家id")
+    private Long userId;
+
+    /**
+     * 玩家账号
+     */
+    @ApiModelProperty(notes = "玩家账号")
+    private String userName;
+
+    /**
+     * 玩家昵称
+     */
+    @ApiModelProperty(notes = "玩家昵称")
+    private String nickname;
+
+    /**
+     * 绑定手机号码
+     */
+    @ApiModelProperty(notes = "绑定手机号码")
+    private String mobile;
+
+    /**
+     * 真实姓名
+     */
+    @ApiModelProperty(notes = "真实姓名")
+    private String realName;
+
+    /**
+     * 注册IP
+     */
+    @ApiModelProperty(notes = "注册IP")
+    private String regIp;
+
+    /**
+     * 是否实名认证
+     */
+    @ApiModelProperty(notes = "是否实名认证")
+    private Boolean isAuth;
+
+    /**
+     * 玩家手机绑定状态
+     */
+    @ApiModelProperty(notes = "玩家手机绑定状态")
+    private Boolean isBindMobile;
+
+    /**
+     * cp名称对应的id
+     */
+    @ApiModelProperty(notes = "cp名称对应的id")
+    private Long cpId;
+
+    /**
+     * 游戏名称对应的id
+     */
+    @ApiModelProperty(notes = "游戏名称对应的id")
+    private Long gameId;
+
+    /**
+     * 游戏应用类型对应的id
+     */
+    @ApiModelProperty(notes = "游戏应用类型对应的id")
+    private Long gameCategoryId;
+
+    /**
+     * 最近充值开始时间(开始玩开始时间请使用beginDate参数)
+     */
+    @ApiModelProperty(notes = "最近充值开始时间(注册开始时间请使用beginDate参数)")
+    private LocalDate rechargeBeginDate;
+
+    /**
+     * 最近充值结束时间(开始玩结束时间请使用endDate参数)
+     */
+    @ApiModelProperty(notes = "最近充值结束时间(注册结束时间请使用endDate参数)")
+    private LocalDate rechargeEndDate;
+
+    /**
+     * 是否充值
+     */
+    @ApiModelProperty(notes = "是否充值, true : 是, false : 否, 全部 : null或者不传")
+    private Boolean isRecharge;
+
+    /**
+     * 角色vip
+     */
+    @ApiModelProperty(notes = "角色vip, 全部 : null或者不传")
+    private Integer vipLevel;
+
+    /**
+     * 玩家状态, -1 为冻结状态, 1 为试玩状态 2为正常状态
+     */
+    @ApiModelProperty(notes = "玩家状态, -1 为冻结状态, 1 为试玩状态 2为正常状态")
+    private Integer status;
+
+    /**
+     * 注册渠道对应的id
+     */
+    @ApiModelProperty(notes = "注册渠道对应的id")
+    private Long channelId;
+
+    /**
+     * 归因推广账号
+     */
+    @ApiModelProperty(notes = "归因推广账号")
+    private Long accountId;
+
+    /**
+     * 归因投放人员
+     */
+    @ApiModelProperty(notes = "归因投放人员")
+    private Long pitcherId;
+
+    /**
+     * 客服id
+     */
+    @ApiModelProperty(notes = "客服id")
+    private Long customerId;
+
+    /**
+     * 归因广告id
+     */
+    @ApiModelProperty(notes = "归因广告id")
+    private String adId;
+
+    /**
+     * 是否GS
+     */
+    @ApiModelProperty(notes = "是否GS")
+    private Boolean isGs;
+
+    /**
+     * 是否切量
+     */
+    @ApiModelProperty(notes = "是否切量")
+    private Boolean isCutCount;
+
+
+}

+ 180 - 0
game-module/game-manage/src/main/java/com/zanxiang/manage/domain/vo/UserListVO.java

@@ -0,0 +1,180 @@
+package com.zanxiang.manage.domain.vo;
+
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import java.math.BigDecimal;
+import java.time.LocalDateTime;
+
+/**
+ * @author : lingfeng
+ * @time : 2022-07-06
+ * @description : 用户信息展示
+ */
+@Data
+public class UserListVO {
+
+    /**
+     * 玩家id
+     */
+    @ApiModelProperty(notes = "玩家id")
+    private Long id;
+
+    /**
+     * 玩家账号
+     */
+    @ApiModelProperty(notes = "玩家账号")
+    private String username;
+
+    /**
+     * 玩家昵称
+     */
+    @ApiModelProperty(notes = "玩家昵称")
+    private String nickname;
+
+    /**
+     * 玩家头像
+     */
+    @ApiModelProperty(notes = "玩家头像")
+    private String avatar;
+
+    /**
+     * 注册IP
+     */
+    @ApiModelProperty(notes = "注册IP")
+    private String regIp;
+
+    /**
+     * 注册时间
+     */
+    @ApiModelProperty(notes = "注册时间")
+    private LocalDateTime createTime;
+
+    /**
+     * 注册渠道id
+     */
+    @ApiModelProperty(notes = "注册渠道id")
+    private Long channelId;
+
+    /**
+     * cp名称
+     */
+    @ApiModelProperty(notes = "cp名称")
+    private Long cpId;
+
+    /**
+     * 游戏id
+     */
+    @ApiModelProperty(notes = "游戏id")
+    private Long gameId;
+
+    /**
+     * 游戏应用类型id
+     */
+    @ApiModelProperty(notes = "游戏应用类型id")
+    private Long gameCategoryId;
+
+    /**
+     * 归因投放人员
+     */
+    @ApiModelProperty(notes = "归因投放人员")
+    private Long pitcherId;
+
+    /**
+     * 归因推广账号
+     */
+    @ApiModelProperty(notes = "归因推广账号")
+    private Long accountId;
+
+    /**
+     * 归因媒体id
+     */
+    @ApiModelProperty(notes = "归因媒体id")
+    private Long mediaId;
+
+    /**
+     * 归因广告id
+     */
+    @ApiModelProperty(notes = "归因广告id")
+    private Long adId;
+
+    /**
+     * 真实姓名
+     */
+    @ApiModelProperty(notes = "真实姓名")
+    private String realName;
+
+    /**
+     * 绑定手机号码
+     */
+    @ApiModelProperty(notes = "绑定手机号码")
+    private String mobile;
+
+    /**
+     * 绑定支付宝账号
+     */
+    @ApiModelProperty(notes = "绑定支付宝账号")
+    private String aliPay;
+
+    /**
+     * 充值金额
+     */
+    @ApiModelProperty(notes = "充值金额")
+    private BigDecimal rechargeMoney;
+
+    /**
+     * 平台币余额
+     */
+    @ApiModelProperty(notes = "平台币余额")
+    private BigDecimal platformCoin;
+
+    /**
+     * 充值次数
+     */
+    @ApiModelProperty(notes = "充值次数")
+    private Integer rechargeCount;
+
+    /**
+     * 创角色数
+     */
+    @ApiModelProperty(notes = "创角色数")
+    private Integer roleCount;
+
+    /**
+     * 客服id
+     */
+    @ApiModelProperty(notes = "客服id")
+    private Long customerId;
+
+    /**
+     * 是否GS
+     */
+    @ApiModelProperty(notes = "是否GS")
+    private Boolean isGs;
+
+    /**
+     * 玩家vip(所有角色中的最高vip等级)
+     */
+    @ApiModelProperty(notes = "角色vip")
+    private Integer vipMax;
+
+    /**
+     * 最近登录时间
+     */
+    @ApiModelProperty(notes = "最近登录时间")
+    private LocalDateTime updateTime;
+
+    /**
+     * 最近充值时间
+     */
+    @ApiModelProperty(notes = "最近充值时间")
+    private LocalDateTime lastRechargeTime;
+
+    /**
+     * 玩家状态, -1 为冻结状态, 1 为试玩状态 2为正常状态
+     */
+    @ApiModelProperty(notes = "玩家状态, -1 为冻结状态, 1 为试玩状态 2为正常状态")
+    private Integer status;
+
+
+}

+ 8 - 2
game-module/game-manage/src/main/java/com/zanxiang/manage/service/Impl/UserExtServiceImpl.java

@@ -41,6 +41,13 @@ public class UserExtServiceImpl extends ServiceImpl<UserExtMapper, UserExt> impl
     @Autowired
     private UserService userService;
 
+    /**
+     * 多条件查询用户拓展信息
+     */
+    private List<UserExtDTO> getUserExtList(String realName, String regIp, Boolean isAuth) {
+        return null;
+    }
+
     /**
      * 注册ip相关条件查询用户拓展信息
      *
@@ -66,8 +73,7 @@ public class UserExtServiceImpl extends ServiceImpl<UserExtMapper, UserExt> impl
      * @param regIp : 玩家注册ip
      * @return : 返回玩家信息列表
      */
-    @Override
-    public List<UserExtDTO> getByRegIp(String regIp) {
+    private List<UserExtDTO> getByRegIp(String regIp) {
         if (Strings.isBlank(regIp)) {
             return Collections.emptyList();
         }

+ 14 - 0
game-module/game-manage/src/main/java/com/zanxiang/manage/service/Impl/UserServiceImpl.java

@@ -2,6 +2,7 @@ package com.zanxiang.manage.service.Impl;
 
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.zanxiang.common.exception.BaseException;
@@ -11,8 +12,10 @@ import com.zanxiang.manage.domain.dto.ChannelDTO;
 import com.zanxiang.manage.domain.dto.GameDTO;
 import com.zanxiang.manage.domain.dto.UserDTO;
 import com.zanxiang.manage.domain.dto.UserExtDTO;
+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.UserListVO;
 import com.zanxiang.manage.domain.vo.UserVO;
 import com.zanxiang.manage.service.*;
 import com.zanxiang.mybatis.entity.User;
@@ -52,6 +55,17 @@ public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements Us
     @Autowired
     private GameUserService gameUserService;
 
+    /**
+     * 玩家列表查询
+     *
+     * @param param : 查询参数
+     * @return : 返回单页玩家数据
+     */
+    @Override
+    public IPage<UserListVO> list(UserListParam param) {
+        return null;
+    }
+
     /**
      * 用户信息更新
      *

+ 0 - 8
game-module/game-manage/src/main/java/com/zanxiang/manage/service/UserExtService.java

@@ -25,14 +25,6 @@ public interface UserExtService extends IService<UserExt> {
      */
     Map<Long, UserExtDTO> regIpCondition(String regIp);
 
-    /**
-     * 根据玩家注册ip查询
-     *
-     * @param regIp : 玩家注册ip
-     * @return : 返回玩家信息列表
-     */
-    List<UserExtDTO> getByRegIp(String regIp);
-
     /**
      * 根据玩家id查询
      *

+ 11 - 0
game-module/game-manage/src/main/java/com/zanxiang/manage/service/UserService.java

@@ -1,8 +1,11 @@
 package com.zanxiang.manage.service;
 
+import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.service.IService;
 import com.zanxiang.manage.domain.dto.UserDTO;
+import com.zanxiang.manage.domain.params.UserListParam;
 import com.zanxiang.manage.domain.params.UserUpdateParam;
+import com.zanxiang.manage.domain.vo.UserListVO;
 import com.zanxiang.manage.domain.vo.UserVO;
 import com.zanxiang.mybatis.entity.User;
 
@@ -16,6 +19,14 @@ import java.util.Map;
  */
 public interface UserService extends IService<User> {
 
+    /**
+     * 玩家列表查询
+     *
+     * @param param : 查询参数
+     * @return : 返回单页玩家数据
+     */
+    IPage<UserListVO> list(UserListParam param);
+
     /**
      * 用户信息更新
      *

+ 41 - 0
game-module/game-mybatis/src/main/java/com/zanxiang/mybatis/entity/User.java

@@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.annotation.TableId;
 import com.baomidou.mybatisplus.annotation.TableName;
 import lombok.*;
 
+import java.math.BigDecimal;
 import java.time.LocalDateTime;
 
 /**
@@ -91,6 +92,46 @@ public class User {
      */
     private Long channel;
 
+    /**
+     * 充值次数
+     */
+    private Integer rechargeCount;
+
+    /**
+     * 充值金额
+     */
+    private BigDecimal rechargeMoney;
+
+    /**
+     * 最近充值时间
+     */
+    private LocalDateTime lastRechargeTime;
+
+    /**
+     * 平台币余额
+     */
+    private BigDecimal platformCoin;
+
+    /**
+     * 创角数
+     */
+    private Integer roleCount;
+
+    /**
+     * 是否GS
+     */
+    private Boolean isGs;
+
+    /**
+     * 客服id
+     */
+    private Long customerId;
+
+    /**
+     * 拥有角色最高vip等级
+     */
+    private Integer vipMax;
+
     /**
      * 注册时间
      */