fix(planting-service): 修复 identity-service 响应解析

identity-service 响应被 TransformInterceptor 包装为 { success, data }
需要从 response.data.data 获取实际用户信息

🤖 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-25 08:47:43 -08:00
parent 48f4ed60a6
commit 484cc99636
1 changed files with 3 additions and 2 deletions

View File

@ -153,11 +153,12 @@ export class IdentityServiceClient {
`getUserDetailBySequence(${accountSequence})`,
async () => {
const response = await firstValueFrom(
this.httpService.get<UserDetailInfo>(
this.httpService.get<{ success: boolean; data: UserDetailInfo }>(
`${this.baseUrl}/api/v1/internal/users/${accountSequence}/detail`,
),
);
return response.data;
// identity-service 的响应被 TransformInterceptor 包装为 { success, data }
return response.data?.data || null;
},
);
} catch (error) {