优化平台商户管理表格列宽分布

This commit is contained in:
yml2213
2026-08-04 11:05:01 +08:00
parent c015def4cd
commit 627d5cafa6
+11 -10
View File
@@ -169,22 +169,22 @@ export default function PlatformMerchants() {
} }
const columns: ColumnsType<Merchant> = [ const columns: ColumnsType<Merchant> = [
{ title: 'ID', dataIndex: 'id', width: 80 }, { title: 'ID', dataIndex: 'id', width: 70, align: 'center' },
{ title: '编码', dataIndex: 'code', width: 180, render: (v) => <Typography.Text code copyable>{v}</Typography.Text> }, { title: '编码', dataIndex: 'code', width: 160, render: (v) => <Typography.Text code copyable={{ text: v }}>{v}</Typography.Text> },
{ title: '名称', dataIndex: 'name', ellipsis: true }, { title: '商户名称', dataIndex: 'name', width: 200, ellipsis: true, render: (v) => <span style={{ fontWeight: 600, color: '#0f172a' }}>{v}</span> },
{ title: '联系人', dataIndex: 'contact_name', width: 120, render: (v) => v || '-' }, { title: '联系人', dataIndex: 'contact_name', width: 120, render: (v) => v || '-' },
{ title: '联系方式', dataIndex: 'contact_info', width: 160, render: (v) => v || '-' }, { title: '联系方式', dataIndex: 'contact_info', width: 150, render: (v) => v || '-' },
{ {
title: '手续费', title: '手续费',
key: 'fee', key: 'fee',
width: 160, width: 140,
render: (_, r) => render: (_, r) =>
r.fee_type === 'fixed' r.fee_type === 'fixed'
? `固定 ${r.fee_fixed_amount} 积分/单` ? `固定 ${r.fee_fixed_amount} 积分/单`
: `${(r.fee_rate_bp / 100).toFixed(2)}%`, : `${(r.fee_rate_bp / 100).toFixed(2)}%`,
}, },
{ {
title: '功能', title: '开通功能',
dataIndex: 'features', dataIndex: 'features',
width: 220, width: 220,
render: (v) => ( render: (v) => (
@@ -212,11 +212,12 @@ export default function PlatformMerchants() {
</span> </span>
), ),
}, },
{ title: '创建时间', dataIndex: 'created_at', width: 180, render: formatDateTime }, { title: '创建时间', dataIndex: 'created_at', width: 170, render: formatDateTime },
{ {
title: '操作', title: '操作',
key: 'action', key: 'action',
width: 260, width: 240,
fixed: 'right',
render: (_, record) => ( render: (_, record) => (
<Space size={0}> <Space size={0}>
<Button <Button
@@ -308,7 +309,7 @@ export default function PlatformMerchants() {
loading={loading} loading={loading}
columns={columns} columns={columns}
dataSource={data.list} dataSource={data.list}
tableLayout="fixed" scroll={{ x: 1400 }}
pagination={{ pagination={{
current: data.page, current: data.page,
pageSize: data.size, pageSize: data.size,