From 57d23abe9622937039e8e304a91a2922134150d7 Mon Sep 17 00:00:00 2001 From: tianfeng <769204422@qq.com> Date: Mon, 29 Dec 2025 18:38:00 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=B9=B4=E6=8A=BD=E5=A5=96=E6=B4=BB?= =?UTF-8?q?=E5=8A=A8=E5=8F=91=E6=94=BE=E5=88=B8=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../gift/strategy/GiftCountStrategy.java | 31 +++---------------- .../other/app/listener/task/TaskListener.java | 18 +---------- 2 files changed, 6 insertions(+), 43 deletions(-) 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);