Ver Fonte

feat : 角色授权分组新增参数03

bilingfeng há 1 ano atrás
pai
commit
1c3b5ce60f

+ 2 - 2
game-module/game-module-base/src/main/java/com/zanxiang/game/module/base/pojo/dto/GameServerDTO.java

@@ -149,9 +149,9 @@ public class GameServerDTO implements Serializable {
         private Long id;
 
         /**
-         * 游戏id
+         * 超父游戏id
          */
-        private Long gameId;
+        private Long superGameId;
 
         /**
          * 区服id

+ 1 - 1
game-module/game-module-manage/src/main/java/com/zanxiang/game/module/manage/ManageApplication.java

@@ -23,7 +23,7 @@ public class ManageApplication {
 
     public static void main(String[] args) {
         SpringApplication.run(ManageApplication.class, args);
-        System.out.println("赞象Manage服务启动成功 < (角色授权分组接口修改´1・・)ノ(._.`) \n" +
+        System.out.println("赞象Manage服务启动成功 < (角色授权分组接口修改´3・・)ノ(._.`) \n" +
                 "___  ___  ___   _   _   ___  _____  _____ \n" +
                 "|  \\/  | / _ \\ | \\ | | / _ \\|  __ \\|  ___|\n" +
                 "| .  . |/ /_\\ \\|  \\| |/ /_\\ \\ |  \\/| |__  \n" +

+ 5 - 1
game-module/game-module-manage/src/main/java/com/zanxiang/game/module/manage/rpc/impl/GameServerRpcImpl.java

@@ -53,7 +53,11 @@ public class GameServerRpcImpl implements IGameServerRpc {
             List<GameServerDTO.GameServerBean> gameServerBeanList = gameServerService.list(new LambdaQueryWrapper<GameServer>()
                     .eq(GameServer::getGameId, supperGameId)
                     .eq(GameServer::getIsSourceServer, Boolean.TRUE)
-            ).stream().map(gameServer -> BeanUtil.copy(gameServer, GameServerDTO.GameServerBean.class)).collect(Collectors.toList());
+            ).stream().map(gameServer -> {
+                GameServerDTO.GameServerBean gameServerBean = BeanUtil.copy(gameServer, GameServerDTO.GameServerBean.class);
+                gameServerBean.setSuperGameId(supperGameId);
+                return gameServerBean;
+            }).collect(Collectors.toList());
             //添加到集合
             superGameServerList.add(GameServerDTO.SuperGameServerBean.builder()
                     .superGameId(supperGameId)

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

@@ -16,7 +16,6 @@ import com.zanxiang.game.module.manage.pojo.vo.GameAuthRoleGroupVO;
 import com.zanxiang.game.module.manage.service.IGameAuthRoleGroupService;
 import com.zanxiang.game.module.mybatis.entity.GameAuthRoleGroup;
 import com.zanxiang.game.module.mybatis.mapper.GameAuthRoleGroupMapper;
-import com.zanxiang.module.util.JsonUtil;
 import com.zanxiang.module.util.bean.BeanUtil;
 import lombok.extern.slf4j.Slf4j;
 import org.apache.dubbo.config.annotation.DubboReference;
@@ -57,17 +56,7 @@ public class GameAuthRoleGroupServiceImpl extends ServiceImpl<GameAuthRoleGroupM
         List<Long> userIdList = records.stream().map(GameAuthRoleGroupVO::getUserId)
                 .distinct().collect(Collectors.toList());
         Map<Long, String> userNameMap = sysUserRpc.getUserNameByIds(userIdList).getData();
-
-        log.error("获取授权角色名字, userNameMap : {}", JsonUtil.toString(userNameMap));
-
         records.forEach(r -> r.setUserName(userNameMap.get(r.getUserId())));
-
-        log.error("设置名字之后, records : {}", JsonUtil.toString(records));
-
-
-        log.error("设置名字之后, gameAuthRoleGroupPage : {}", JsonUtil.toString(gameAuthRoleGroupPage));
-
-
         return gameAuthRoleGroupPage;
     }