feat: 账号导入列表移除块级标题、刷新改图标,新增账号名称列(成功任务回填作者名)
This commit is contained in:
@@ -28,6 +28,7 @@ interface Job {
|
||||
attempts?: number;
|
||||
failure_reason?: string;
|
||||
created_at?: string;
|
||||
author_name?: string;
|
||||
}
|
||||
|
||||
interface FormValues {
|
||||
@@ -115,6 +116,18 @@ export default function Page() {
|
||||
}
|
||||
|
||||
const columns: ColumnsType<Job> = [
|
||||
{
|
||||
title: '账号名称',
|
||||
dataIndex: 'author_name',
|
||||
render: (value?: string, job?: Job) =>
|
||||
value ? (
|
||||
<Typography.Text strong>{value}</Typography.Text>
|
||||
) : (
|
||||
<Typography.Text type="secondary" style={{ fontSize: 12 }}>
|
||||
{job?.status === 'failed' ? '解析失败' : '解析中'}
|
||||
</Typography.Text>
|
||||
),
|
||||
},
|
||||
{
|
||||
title: '分享链接',
|
||||
dataIndex: 'share_url',
|
||||
@@ -167,14 +180,8 @@ export default function Page() {
|
||||
return (
|
||||
<Card variant="outlined">
|
||||
{contextHolder}
|
||||
<div style={{ marginBottom: 16, display: 'flex', justifyContent: 'space-between', alignItems: 'flex-start' }}>
|
||||
<div>
|
||||
<Typography.Title level={5} style={{ marginBottom: 4 }}>分享链接解析任务</Typography.Title>
|
||||
<Typography.Text type="secondary">待处理和失败的分享链接独立展示;成功后才会进入竞品作者监控。</Typography.Text>
|
||||
</div>
|
||||
<Button icon={<ReloadOutlined />} onClick={loadShareJobs} disabled={pending}>
|
||||
刷新
|
||||
</Button>
|
||||
<div style={{ marginBottom: 16, display: 'flex', justifyContent: 'flex-end' }}>
|
||||
<Button icon={<ReloadOutlined />} onClick={loadShareJobs} disabled={pending} aria-label="刷新" />
|
||||
</div>
|
||||
{error ? (
|
||||
<Alert type="error" showIcon style={{ marginBottom: 16 }} title={error.message} action={<Button size="small" onClick={loadShareJobs}>重试</Button>} />
|
||||
|
||||
Reference in New Issue
Block a user