diff --git a/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/listener/gift/strategy/GiftCountStrategy.java b/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/listener/gift/strategy/GiftCountStrategy.java index da17900a..44586448 100644 --- a/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/listener/gift/strategy/GiftCountStrategy.java +++ b/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/listener/gift/strategy/GiftCountStrategy.java @@ -206,6 +206,9 @@ public class GiftCountStrategy implements GiftStrategy { // 家族 processFamily(runningWater, isLuckyGift, luckyGiftRatio); + // Spins 送礼物任务 + handleSpinsGiftTask(runningWater); + giftGiveRunningWaterService.addLog(runningWater.getId(), "结束:礼物统计相关"); } @@ -690,36 +693,12 @@ public class GiftCountStrategy implements GiftStrategy { int giftCount = incrementDailyGiftCount(userId, quantity); log.info("Spins送礼物任务, userId={}, giftCount={}", userId, giftCount); - - // 处理送礁1个礼物任务 - spinsUserTaskProgressService.updateTaskProgress( - new SpinsTaskProgressUpdateCmd() - .setUserId(userId) - .setTaskCode("SPINS_SEND_GIFT_1") - .setProgressValue(giftCount) - ); - // 处理送出3个礼物任务 + // 处理送出5个礼物任务 spinsUserTaskProgressService.updateTaskProgress( new SpinsTaskProgressUpdateCmd() .setUserId(userId) - .setTaskCode("SPINS_SEND_GIFT_3") - .setProgressValue(giftCount) - ); - - // 处理送出10个礼物任务 - spinsUserTaskProgressService.updateTaskProgress( - new SpinsTaskProgressUpdateCmd() - .setUserId(userId) - .setTaskCode("SPINS_SEND_GIFT_10") - .setProgressValue(giftCount) - ); - - // 处理送出15个礼物任务 - spinsUserTaskProgressService.updateTaskProgress( - new SpinsTaskProgressUpdateCmd() - .setUserId(userId) - .setTaskCode("SPINS_SEND_GIFT_15") + .setTaskCode("SPINS_SEND_GIFT_5") .setProgressValue(giftCount) ); diff --git a/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/listener/task/TaskListener.java b/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/listener/task/TaskListener.java index 0b68b5a7..5d6bdc9b 100644 --- a/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/listener/task/TaskListener.java +++ b/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/listener/task/TaskListener.java @@ -155,7 +155,7 @@ public class TaskListener implements MessageListener { } // 处理 Spins 上麦任务进度 -// handleSpinsMicTask(eventBody.getUserId(), inc); + handleSpinsMicTask(eventBody.getUserId(), inc); } /** @@ -170,14 +170,6 @@ public class TaskListener implements MessageListener { try { int micTime = Integer.parseInt(micTimeStr); - - // 处理上麦15分钟任务 - spinsUserTaskProgressService.updateTaskProgress( - new SpinsTaskProgressUpdateCmd() - .setUserId(userId) - .setTaskCode("SPINS_MIC_15_MIN") - .setProgressValue(micTime) - ); // 处理上麦30分钟任务 spinsUserTaskProgressService.updateTaskProgress( @@ -195,14 +187,6 @@ public class TaskListener implements MessageListener { .setProgressValue(micTime) ); - // 处理上麦2小时任务 - spinsUserTaskProgressService.updateTaskProgress( - new SpinsTaskProgressUpdateCmd() - .setUserId(userId) - .setTaskCode("SPINS_MIC_2_HOUR") - .setProgressValue(micTime) - ); - log.info("Spins上麦任务进度更新成功, userId={}, micTime={}", userId, micTime); } catch (Exception e) { log.error("处理Spins上麦任务进度失败, userId={}, micTimeStr={}", userId, micTimeStr, e);