fix(identity-service): 修复 InternalController 未注册问题

- 在 app.module.ts 的内联 ApiModule 中添加 InternalController
- 添加 InfrastructureModule 导入和 UserAccountRepositoryImpl provider
- 修正 authorization-service 的 identity-service URL 默认值

问题原因:app.module.ts 定义了内联 ApiModule,不是导入的 api.module.ts

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
hailin 2025-12-23 03:04:57 -08:00
parent a194fcad72
commit 1d21ae8ff7
2 changed files with 5 additions and 2 deletions

View File

@ -25,7 +25,7 @@ export class IdentityServiceClient implements OnModuleInit {
private readonly enabled: boolean;
constructor(private readonly configService: ConfigService) {
this.baseUrl = this.configService.get<string>('IDENTITY_SERVICE_URL') || 'http://identity-service:3001';
this.baseUrl = this.configService.get<string>('IDENTITY_SERVICE_URL') || 'http://rwa-identity-service:3000';
this.enabled = this.configService.get<boolean>('IDENTITY_SERVICE_ENABLED') !== false;
}

View File

@ -22,6 +22,7 @@ import { HealthController } from '@/api/controllers/health.controller';
import { ReferralsController } from '@/api/controllers/referrals.controller';
import { AuthController } from '@/api/controllers/auth.controller';
import { TotpController } from '@/api/controllers/totp.controller';
import { InternalController } from '@/api/controllers/internal.controller';
// Application Services
import { UserApplicationService } from '@/application/services/user-application.service';
@ -136,14 +137,16 @@ export class ApplicationModule {}
// ============ API Module ============
@Module({
imports: [ApplicationModule],
imports: [ApplicationModule, InfrastructureModule],
controllers: [
HealthController,
UserAccountController,
ReferralsController,
AuthController,
TotpController,
InternalController,
],
providers: [UserAccountRepositoryImpl],
})
export class ApiModule {}