From 454b466993b1d67858aff4299c76a618c8af6303 Mon Sep 17 00:00:00 2001 From: hailin Date: Tue, 23 Dec 2025 07:23:46 -0800 Subject: [PATCH] =?UTF-8?q?fix(authorization):=20=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E8=87=AA=E5=8A=A8=E5=8D=87=E7=BA=A7=E6=A3=80=E6=9F=A5=E8=A2=AB?= =?UTF-8?q?=E6=8F=90=E5=89=8D=E8=BF=94=E5=9B=9E=E8=B7=B3=E8=BF=87=E7=9A=84?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 当认种用户没有授权时,不再提前返回,确保 checkAllTeamAutoUpgrade() 始终被调用,以正确检查所有市/省团队的自动升级条件。 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 --- .../src/infrastructure/kafka/event-consumer.controller.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/backend/services/authorization-service/src/infrastructure/kafka/event-consumer.controller.ts b/backend/services/authorization-service/src/infrastructure/kafka/event-consumer.controller.ts index 836b18b8..4a808682 100644 --- a/backend/services/authorization-service/src/infrastructure/kafka/event-consumer.controller.ts +++ b/backend/services/authorization-service/src/infrastructure/kafka/event-consumer.controller.ts @@ -145,12 +145,11 @@ export class EventConsumerController { UserId.create(userId, teamStats.accountSequence), ) + // 3. 处理每个授权(如果有的话) if (authorizations.length === 0) { - this.logger.debug(`[PLANTING] User ${userId} has no authorizations`) - return + this.logger.debug(`[PLANTING] User ${userId} has no authorizations, skipping individual auth processing`) } - // 3. 处理每个授权 for (const auth of authorizations) { this.logger.debug(`[PLANTING] Processing authorization: ${auth.authorizationId.value}, role=${auth.roleType}, benefitActive=${auth.benefitActive}, status=${auth.status}`)