热门游戏统计下注金额
This commit is contained in:
parent
a828e75885
commit
47e926cfec
@ -125,7 +125,7 @@ public class GameHkysRestController {
|
||||
gameActivityService.handleGameSpendTask(userId, cmd.getCoin());
|
||||
gameActivityService.incKingGameDaily(userId, cmd.getCoin(), cmd.getGameId());
|
||||
} else {
|
||||
gameEventService.onBetEvent(userId, cmd.getCoin());
|
||||
gameEventService.onBetEvent(userId, cmd.getCoin(), gameListConfig);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -194,7 +194,7 @@ public class GameBaishunServiceImpl implements GameBaishunService {
|
||||
gameActivityService.handleGameSpendTask(userId, Math.abs(request.getCurrencyDiff()));
|
||||
gameActivityService.incKingGameDaily(userId, request.getCurrencyDiff(), request.getGameId());
|
||||
} else {
|
||||
gameEventService.onBetEvent(userId, request.getCurrencyDiff());
|
||||
gameEventService.onBetEvent(userId, request.getCurrencyDiff(), gameListConfig);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -122,7 +122,7 @@ public class HkysServiceImpl implements GameHkysService {
|
||||
gameActivityService.handleGameSpendTask(userId, param.getCoin());
|
||||
gameActivityService.incKingGameDaily(userId, param.getCoin(), param.getGameId());
|
||||
} else {
|
||||
gameEventService.onBetEvent(userId, param.getCoin());
|
||||
gameEventService.onBetEvent(userId, param.getCoin(), gameConfig);
|
||||
}
|
||||
|
||||
return new HkysResponse<UpdateUserCoinResponse>()
|
||||
|
||||
@ -169,7 +169,7 @@ public class HotGameServiceImpl implements HotGameService {
|
||||
gameActivityService.incKingGameDaily(userId, param.getCoin(), param.getGameId());
|
||||
incFruitPartyRankingActivity(param);
|
||||
} else {
|
||||
gameEventService.onBetEvent(userId, param.getCoin());
|
||||
gameEventService.onBetEvent(userId, param.getCoin(), gameConfig);
|
||||
}
|
||||
|
||||
return new HotGameResponse<HotGameCoin>()
|
||||
|
||||
@ -177,7 +177,7 @@ public class YomiGameServiceImpl implements YomiGameService {
|
||||
gameActivityService.handleGameSpendTask(userId, cmd.getGold());
|
||||
gameActivityService.incKingGameDaily(userId, cmd.getGold(), gameIdStr);
|
||||
} else {
|
||||
gameEventService.onBetEvent(userId, cmd.getGold());
|
||||
gameEventService.onBetEvent(userId, cmd.getGold(), gameConfig);
|
||||
}
|
||||
|
||||
return new YomiBalanceCO(currentBalance);
|
||||
|
||||
@ -129,7 +129,6 @@ public class GameEventService {
|
||||
return;
|
||||
}
|
||||
sendBroadcast(userId, gold, gameConfig);
|
||||
incGameRankingRecord(gold, gameOrigin, gameConfig);
|
||||
incGameRankingActivity(userId, gold, gameConfig.getGameId(), gameConfig.getSysOrigin());
|
||||
}
|
||||
|
||||
@ -157,11 +156,11 @@ public class GameEventService {
|
||||
);
|
||||
}
|
||||
|
||||
private void incGameRankingRecord(Long gold, String gameOrigin, GameListConfig gameConfig) {
|
||||
private void incGameRankingRecord(Long gold, GameListConfig gameConfig) {
|
||||
gameRankingGateway.incrementPrizeAmount(
|
||||
GameRankingIncrementCmd.builder()
|
||||
.gameOrigin(gameOrigin)
|
||||
.gameId(gameConfig.getGameId())
|
||||
.gameOrigin(gameConfig.getGameOrigin())
|
||||
.gameId(gameConfig.getId().toString())
|
||||
.gameName(gameConfig.getName())
|
||||
.gameCover(gameConfig.getCover())
|
||||
.gameUrl(gameConfig.getGameCode())
|
||||
@ -193,9 +192,9 @@ public class GameEventService {
|
||||
// ------------------------------------------------------------------ //
|
||||
|
||||
/**
|
||||
* 投注后的业务增强:房间日任务
|
||||
* 投注后的业务增强:房间日任务 + 游戏排行榜累计下注金额
|
||||
*/
|
||||
public void onBetEvent(Long userId, Long gold) {
|
||||
public void onBetEvent(Long userId, Long gold, GameListConfig gameConfig) {
|
||||
RoomDailyTaskCode taskType = RoomDailyTaskCode.PERSONAL_GAME_CONSUME;
|
||||
String redisKey = "room:daily:task:progress:" + taskType.name() + ":" + userId
|
||||
+ ":" + ZonedDateTimeAsiaRiyadhUtils.now().toLocalDate();
|
||||
@ -207,5 +206,8 @@ public class GameEventService {
|
||||
.setTaskCode(taskType.name())
|
||||
.setProgressValue(total.intValue())
|
||||
);
|
||||
if (gameConfig != null) {
|
||||
incGameRankingRecord(Math.abs(gold), gameConfig);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user