refactor(reward): remove unused transferExpiredRewardToOperationAccount method
Expired referral rewards are transferred to headquarters community (seq=1), not operation account. Remove the unused method to avoid confusion. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
6f46a8633f
commit
1afdc2ce17
|
|
@ -67,38 +67,4 @@ export class AuthorizationServiceClient implements IAuthorizationServiceClient {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* 通知过期奖励转入运营账户
|
|
||||||
* 根据文档:过期的直推奖励应转入运营账户
|
|
||||||
*/
|
|
||||||
async transferExpiredRewardToOperationAccount(params: {
|
|
||||||
amount: number;
|
|
||||||
sourceRewardId: bigint;
|
|
||||||
memo?: string;
|
|
||||||
}): Promise<void> {
|
|
||||||
try {
|
|
||||||
const response = await fetch(
|
|
||||||
`${this.baseUrl}/api/v1/system-accounts/receive-expired-reward`,
|
|
||||||
{
|
|
||||||
method: 'POST',
|
|
||||||
headers: {
|
|
||||||
'Content-Type': 'application/json',
|
|
||||||
},
|
|
||||||
body: JSON.stringify({
|
|
||||||
accountType: 'OPERATION_ACCOUNT',
|
|
||||||
amount: params.amount,
|
|
||||||
sourceRewardId: params.sourceRewardId.toString(),
|
|
||||||
memo: params.memo || '过期奖励转入',
|
|
||||||
}),
|
|
||||||
},
|
|
||||||
);
|
|
||||||
|
|
||||||
if (!response.ok) {
|
|
||||||
this.logger.warn(`Failed to transfer expired reward to operation account`);
|
|
||||||
}
|
|
||||||
} catch (error) {
|
|
||||||
this.logger.error(`Error transferring expired reward:`, error);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue