fix(admin-web): update account names and change USDT to 绿积分

- Rename account labels:
  - 成本账户 → 总部储备
  - 运营账户 → 运营账户1
  - 总部社区 → 运营账户2
  - RWAD待发放池 → 积分股池
- Change all USDT displays to 绿积分 throughout the system account report
- Add getAssetTypeLabel function for asset type mapping in ledger details

🤖 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 2026-01-04 23:58:16 -08:00
parent 44a1023cdd
commit 0f3c26c6fa
2 changed files with 39 additions and 21 deletions

View File

@ -185,13 +185,14 @@ export default function SystemAccountsTab() {
/**
*
* [2026-01-05] USDT改为绿积分
*/
function FixedAccountsSection({ data }: { data: SystemAccountReportResponse['fixedAccounts'] }) {
const accounts = [
{ key: 'costAccount', label: '成本账户', sequence: 'S0000000001', data: data.costAccount },
{ key: 'operationAccount', label: '运营账户', sequence: 'S0000000002', data: data.operationAccount },
{ key: 'hqCommunity', label: '总部社区', sequence: 'S0000000003', data: data.hqCommunity },
{ key: 'rwadPoolPending', label: 'RWAD待发放池', sequence: 'S0000000004', data: data.rwadPoolPending },
{ key: 'costAccount', label: '总部储备', sequence: 'S0000000001', data: data.costAccount },
{ key: 'operationAccount', label: '运营账户1', sequence: 'S0000000002', data: data.operationAccount },
{ key: 'hqCommunity', label: '运营账户2', sequence: 'S0000000003', data: data.hqCommunity },
{ key: 'rwadPoolPending', label: '积分股池', sequence: 'S0000000004', data: data.rwadPoolPending },
{ key: 'platformFee', label: '平台手续费', sequence: 'S0000000005', data: data.platformFee },
];
@ -209,19 +210,19 @@ function FixedAccountsSection({ data }: { data: SystemAccountReportResponse['fix
<div className={styles.statRow}>
<span className={styles.statLabel}></span>
<span className={styles.statValue}>
{accountData ? formatAmount(accountData.usdtBalance) : '0.00'} USDT
{accountData ? formatAmount(accountData.usdtBalance) : '0.00'} 绿
</span>
</div>
<div className={styles.statRow}>
<span className={styles.statLabel}></span>
<span className={styles.statValue}>
{accountData ? formatAmount(accountData.totalReceived) : '0.00'} USDT
{accountData ? formatAmount(accountData.totalReceived) : '0.00'} 绿
</span>
</div>
<div className={styles.statRow}>
<span className={styles.statLabel}></span>
<span className={styles.statValue}>
{accountData ? formatAmount(accountData.totalTransferred) : '0.00'} USDT
{accountData ? formatAmount(accountData.totalTransferred) : '0.00'} 绿
</span>
</div>
</div>
@ -234,6 +235,7 @@ function FixedAccountsSection({ data }: { data: SystemAccountReportResponse['fix
/**
*
* [2026-01-05] USDT改为绿积分
*/
function RegionAccountsSection({ data, type }: { data: RegionAccountsSummary; type: 'province' | 'city' }) {
const typeLabel = type === 'province' ? '省' : '市';
@ -250,11 +252,11 @@ function RegionAccountsSection({ data, type }: { data: RegionAccountsSummary; ty
</div>
<div className={styles.summaryCard}>
<span className={styles.summaryLabel}></span>
<span className={styles.summaryValue}>{formatAmount(data.summary.totalBalance)} USDT</span>
<span className={styles.summaryValue}>{formatAmount(data.summary.totalBalance)} 绿</span>
</div>
<div className={styles.summaryCard}>
<span className={styles.summaryLabel}></span>
<span className={styles.summaryValue}>{formatAmount(data.summary.totalReceived)} USDT</span>
<span className={styles.summaryValue}>{formatAmount(data.summary.totalReceived)} 绿</span>
</div>
</div>
@ -266,8 +268,8 @@ function RegionAccountsSection({ data, type }: { data: RegionAccountsSummary; ty
<tr>
<th></th>
<th></th>
<th> (USDT)</th>
<th> (USDT)</th>
<th> (绿)</th>
<th> (绿)</th>
<th></th>
</tr>
</thead>
@ -297,6 +299,7 @@ function RegionAccountsSection({ data, type }: { data: RegionAccountsSummary; ty
/**
*
* [2026-01-05] USDT改为绿积分
*/
function OfflineSettlementSection({ data }: { data: SystemAccountReportResponse['offlineSettlement'] }) {
return (
@ -311,7 +314,7 @@ function OfflineSettlementSection({ data }: { data: SystemAccountReportResponse[
</div>
<div className={styles.summaryCard}>
<span className={styles.summaryLabel}></span>
<span className={styles.summaryValue}>{formatAmount(data.totalAmount)} USDT</span>
<span className={styles.summaryValue}>{formatAmount(data.totalAmount)} 绿</span>
</div>
</div>
@ -325,7 +328,7 @@ function OfflineSettlementSection({ data }: { data: SystemAccountReportResponse[
<tr>
<th></th>
<th></th>
<th> (USDT)</th>
<th> (绿)</th>
</tr>
</thead>
<tbody>
@ -351,6 +354,7 @@ function OfflineSettlementSection({ data }: { data: SystemAccountReportResponse[
/**
*
* [2026-01-05] USDT改为绿积分
*/
function ExpiredRewardsSection({ data }: { data: SystemAccountReportResponse['expiredRewards'] }) {
return (
@ -365,7 +369,7 @@ function ExpiredRewardsSection({ data }: { data: SystemAccountReportResponse['ex
</div>
<div className={styles.summaryCard}>
<span className={styles.summaryLabel}></span>
<span className={styles.summaryValue}>{formatAmount(data.totalAmount)} USDT</span>
<span className={styles.summaryValue}>{formatAmount(data.totalAmount)} 绿</span>
</div>
</div>
@ -379,7 +383,7 @@ function ExpiredRewardsSection({ data }: { data: SystemAccountReportResponse['ex
<tr>
<th></th>
<th></th>
<th> (USDT)</th>
<th> (绿)</th>
</tr>
</thead>
<tbody>
@ -406,7 +410,7 @@ function ExpiredRewardsSection({ data }: { data: SystemAccountReportResponse['ex
<tr>
<th></th>
<th></th>
<th> (USDT)</th>
<th> (绿)</th>
</tr>
</thead>
<tbody>
@ -562,8 +566,21 @@ function LedgerSection({
);
}
/**
*
* [2026-01-05] USDT改为绿积分
*/
const getAssetTypeLabel = (assetType: string): string => {
const labels: Record<string, string> = {
USDT: '绿积分',
usdt: '绿积分',
};
return labels[assetType] || assetType;
};
/**
*
* [2026-01-05]
*/
function LedgerAccountCard({
title,
@ -618,7 +635,7 @@ function LedgerAccountCard({
</span>
</td>
<td className={entry.amount >= 0 ? styles.amountPositive : styles.amountNegative}>
{entry.amount >= 0 ? '+' : ''}{formatAmount(entry.amount)} {entry.assetType}
{entry.amount >= 0 ? '+' : ''}{formatAmount(entry.amount)} {getAssetTypeLabel(entry.assetType)}
</td>
<td>{entry.balanceAfter !== null ? formatAmount(entry.balanceAfter) : '-'}</td>
<td className={styles.memo}>{entry.memo || entry.allocationType || '-'}</td>

View File

@ -97,12 +97,13 @@ export interface SystemAccountReportResponse {
/**
*
* [2026-01-05]
*/
export const ACCOUNT_TYPE_LABELS: Record<string, string> = {
COST_ACCOUNT: '成本账户',
OPERATION_ACCOUNT: '运营账户',
HQ_COMMUNITY: '总部社区',
RWAD_POOL_PENDING: 'RWAD待发放池',
COST_ACCOUNT: '总部储备',
OPERATION_ACCOUNT: '运营账户1',
HQ_COMMUNITY: '运营账户2',
RWAD_POOL_PENDING: '积分股池',
PLATFORM_FEE: '平台手续费',
SYSTEM_PROVINCE: '系统省账户',
SYSTEM_CITY: '系统市账户',