会员积分改版V7

This commit is contained in:
2026-08-11 13:23:22 +08:00
parent 809ff47120
commit a49ed802f4
14 changed files with 137 additions and 29 deletions
@@ -1598,6 +1598,9 @@ const AppLayout: React.FC = () => {
fontSize: 20, fontWeight: 800, marginTop: 2,
background: g.gradient, WebkitBackgroundClip: 'text', WebkitTextFillColor: 'transparent',
}}>¥{opt.currentPrice || opt.price}</div>
<Typography.Text type="secondary" style={{ fontSize: 12 }}>
{Number(opt.validityMonths || 1)}
</Typography.Text>
</div>
</div>
</div>
+8 -11
View File
@@ -67,20 +67,17 @@ const CreditRecordsPage: React.FC = () => {
ellipsis: true,
},
{
title: '有效积分变动',
key: 'balanceDelta',
title: '变动积分',
dataIndex: 'amount',
key: 'amount',
width: 140,
align: 'right' as const,
render: (_: unknown, record: any) => {
const delta = record.balanceDelta ?? record.balance_delta ?? record.amount ?? 0;
const expired = record.expiredAmount ?? record.expired_amount ?? 0;
render: (value: number) => {
const delta = Number(value ?? 0);
return (
<div>
<Typography.Text strong style={{ fontWeight: 700, color: delta > 0 ? '#10b981' : delta < 0 ? '#ef4444' : '#64748b', fontSize: 15 }}>
{delta > 0 ? '+' : ''}{delta}
</Typography.Text>
{expired > 0 && <div style={{ color: '#94a3b8', fontSize: 12 }}> {expired}</div>}
</div>
<Typography.Text strong style={{ fontWeight: 700, color: delta > 0 ? '#10b981' : delta < 0 ? '#ef4444' : '#64748b', fontSize: 15 }}>
{delta > 0 ? '+' : ''}{delta}
</Typography.Text>
);
},
},