feat(webui): 超级编导 0 条作品时说清是哪几个活动
Deploy VitePress site to Pages / build (push) Canceled after 0s
Deploy VitePress site to Pages / Deploy (push) Canceled after 0s

实测踩到:按 10-22~10-24 查返回「活动 4 个、作品 0 条」,看着像链接没取到。
那 4 个活动全是排期在未来的(10.26/10.27/10.28/10.29),还没人发布。活动名
里的日期只是名字,不是创建时间 —— 这句也写进空态里。
This commit is contained in:
2026-10-24 16:45:12 +08:00
parent 2b19808f6b
commit 1dca78b6db
4 changed files with 90 additions and 3 deletions
+22 -3
View File
@@ -208,9 +208,28 @@ export function SuperDirTool({ open, onOpenChange }: SuperDirToolProps) {
))}
</div>
) : (
<p className="py-4 text-center font-mono text-[11px] text-cyber-text-muted">
这段时间里没有可导入的作品
</p>
<div className="space-y-1 rounded-md border border-cyber-border-subtle bg-cyber-bg-tertiary/60 px-3 py-2">
<p className="font-mono text-[11px] text-cyber-text-muted">
这段时间创建了 {data.matched_activities.length} 个分发活动,但还没有已发布的作品:
</p>
{data.matched_activities.map((activity) => (
<div
key={activity.id}
className="flex flex-wrap items-center gap-x-2 font-mono text-[10px]"
>
<span className="text-cyber-text-secondary">
{activity.title || `活动 ${activity.id}`}
</span>
<span className="text-cyber-text-muted">
创建 {formatTs(activity.created_at)} · 已发布{' '}
{activity.published_count}/{activity.total_count}
</span>
</div>
))}
<p className="font-mono text-[10px] text-cyber-text-muted">
活动名里的日期只是活动名,不是创建时间;排期在未来的活动通常还没有作品。
</p>
</div>
)}
</>
)}
+12
View File
@@ -599,11 +599,23 @@ export interface SuperDirFailedActivity {
error: string
}
/** 匹配到的分发活动。0 条作品时用它解释「为什么是 0」。 */
export interface SuperDirMatchedActivity {
id: number
title: string
created_at: number
/** 活动里计划/分配的作品数。 */
total_count: number
/** 已经发布出来的作品数。 */
published_count: number
}
export interface SuperDirPreviewResponse {
start: string
end: string
/** 区间内创建的分发活动数。 */
activities: number
matched_activities: SuperDirMatchedActivity[]
/** 能用的作品条数(去重、去掉私密和没发布之后)。 */
videos: number
creators: number