Pārlūkot izejas kodu

Merge branch 'package' of GameCenter/game-center into dev

zhimo 8 mēneši atpakaļ
vecāks
revīzija
fd4321050f

+ 2 - 2
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/service/impl/AdsOrderDetailServiceImpl.java

@@ -431,8 +431,8 @@ public class AdsOrderDetailServiceImpl implements IAdsOrderDetailService {
                 		TIMESTAMPDIFF(SECOND, b.create_time, a.pay_time) as reg_until_pay, -- 注册充值时间差
                 		TIMESTAMPDIFF(SECOND, a.pay_time, NOW()) as pay_until_now, -- 最近充值时间距今(秒)
                 		IF(a.status = 2, IF(a.create_time = i.create_time, 1, 0), 0) as is_first_recharge, -- 是否首充
-                		IF(a.promotion_id = 'null', NULL, a.promotion_id) as promotion_id , -- 计划ID
-                  		IF(a.project_id = 'null' , NULL, a.project_id) as project_id, -- 项目ID(广告ID)
+                		IF(b.promotion_id = 'null', NULL, b.promotion_id) as promotion_id , -- 计划ID
+                  		IF(b.project_id = 'null' , NULL, b.project_id) as project_id, -- 项目ID(广告ID)
                  		IFNULL(l.back_status, 2) as back_status, -- 回传状态:-1-回传失败;0-未回传;1-已回传;2-没有回传数据
                  		IFNULL(l.back_money / 100, null) as back_money, -- 回传金额
                  		l.back_msg as back_msg, -- 回传信息

+ 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服务启动成功 < (服务器迁移, 修正DUBBO通信问题・・)ノ(._.`) \n" +
+        System.out.println("赞象Manage服务启动成功 < (客服权限额外添加兼容・・)ノ(._.`) \n" +
                 "___  ___  ___   _   _   ___  _____  _____ \n" +
                 "|  \\/  | / _ \\ | \\ | | / _ \\|  __ \\|  ___|\n" +
                 "| .  . |/ /_\\ \\|  \\| |/ /_\\ \\ |  \\/| |__  \n" +

+ 1 - 0
game-module/game-module-manage/src/main/java/com/zanxiang/game/module/manage/service/api/CpServerApiService.java

@@ -45,6 +45,7 @@ public class CpServerApiService {
     private RestTemplate restTemplate;
 
     public boolean chatMsgSubmit(ChatSubmitParam param) {
+        log.error("收到游戏聊天内容, param : {}", JsonUtil.toString(param));
         GameSupper gameSupper = gameSupperService.getById(param.getGameId());
         if (gameSupper == null) {
             throw new BaseException("参数错误");

+ 2 - 8
game-module/game-module-manage/src/main/java/com/zanxiang/game/module/manage/service/impl/GameAuthRoleServiceImpl.java

@@ -89,16 +89,10 @@ public class GameAuthRoleServiceImpl extends ServiceImpl<GameAuthRoleMapper, Gam
 
     @Override
     public boolean isCustomer() {
-        //开后门, 开发调试问题的时候用
-        if (SecurityUtil.isAdmin()) {
-            List<Long> backDoorIds = Arrays.asList(123L, 220L);
-            if (backDoorIds.contains(SecurityUtil.getUserId())) {
-                return Boolean.TRUE;
-            }
-        }
         return super.count(new LambdaQueryWrapper<GameAuthRole>()
-                .eq(GameAuthRole::getAuthType, GameAuthEnum.CUSTOMER.getValue())
                 .eq(GameAuthRole::getUserId, SecurityUtil.getUserId())
+                .and(qw -> qw.eq(GameAuthRole::getAuthType, GameAuthEnum.CUSTOMER.getValue())
+                        .or().eq(GameAuthRole::getCustomerPower, Boolean.TRUE))
         ) > 0;
     }
 

+ 5 - 0
game-module/game-module-mybatis/src/main/java/com/zanxiang/game/module/mybatis/entity/GameAuthRole.java

@@ -65,4 +65,9 @@ public class GameAuthRole implements Serializable {
      * 更新时间
      */
     private LocalDateTime updateTime;
+
+    /**
+     * 客服权限
+     */
+    private Boolean customerPower;
 }