diff --git a/web/src/LibraryStorageSection.tsx b/web/src/LibraryStorageSection.tsx index d3a78e3..1493841 100644 --- a/web/src/LibraryStorageSection.tsx +++ b/web/src/LibraryStorageSection.tsx @@ -89,78 +89,81 @@ export function LibraryStorageSection() { )} -
- {policyConfigured - ? `策略:${[ - plan && plan.policy.keep_versions > 0 ? `保留最近 ${plan.policy.keep_versions} 个版本` : '', - plan && plan.policy.keep_days > 0 ? `保留 ${plan.policy.keep_days} 天` : '', - ] - .filter(Boolean) - .join(' + ')}` - : '策略:未设置(不生成清理候选)'} -
-- 受保护版本 {plan?.protected.length ?? 0} 个:生产生效、每库最近封存、每次生产预备份、在飞作业引用, - 不论多久都不会进入候选。 -
- {data.versions.filter((item) => item.protected).length > 0 ? ( -{item.id.slice(0, 12)} {item.kind} · {(item.protected_by ?? []).join('、')}
- - 按策略可考虑清理 {plan.candidates.length} 个版本,独占字节上限{' '} - {formatBytes(plan.reclaim_preview_bytes)}(共享 blob 不会因此释放,这不是可回收空间)。 -
-+ {policyConfigured + ? `策略:${[ + plan && plan.policy.keep_versions > 0 ? `保留最近 ${plan.policy.keep_versions} 个版本` : '', + plan && plan.policy.keep_days > 0 ? `保留 ${plan.policy.keep_days} 天` : '', + ] + .filter(Boolean) + .join(' + ')}` + : '策略:未设置(不生成清理候选)'} +
++ 受保护版本 {plan?.protected.length ?? 0} 个:生产生效、每库最近封存、每次生产预备份、运行中作业引用, + 不论多久都不会进入候选。 +
+ {data.versions.filter((item) => item.protected).length > 0 ? ( +{item.id.slice(0, 12)} {item.kind} · {item.reason.join(';')} ·{' '}
- {formatBytes(item.exclusive_bytes)}
+ {item.id.slice(0, 12)} {item.kind} · {(item.protected_by ?? []).join('、')}
按当前策略没有可清理的候选版本。
- ) - ) : ( -- 保留数量与天数都未设置,按「全部保留」处理:不生成候选,也不提供默认值。 -
- )} - {plan?.blocked.length ? ( -+ 按策略可考虑清理 {plan.candidates.length} 个版本,独占字节上限{' '} + {formatBytes(plan.reclaim_preview_bytes)}(共享归档文件不会因此释放,这不是可回收空间)。 +
+{item.id.slice(0, 12)} {item.kind} · {item.reason.join(';')} ·{' '}
+ {formatBytes(item.exclusive_bytes)}
+ 按当前策略没有可清理的候选版本。
+ ) + ) : ( ++ 保留数量与天数都未设置,按「全部保留」处理:不生成候选,也不提供默认值。 +
+ )} + {plan?.blocked.length ? ( +- 生产端核对不可用:{bindings.production_message}。 - {bindings.production_base_url ? `(生产地址:${bindings.production_base_url})` : ''} + 生产端核对不可用: + {/api key file/i.test(bindings.production_message) + ? '生产 API 读取凭据未配置(不影响整库执行器;整库同步走独立数据库/索引/存储通道)' + : bindings.production_message} + 。{bindings.production_base_url ? `(生产地址:${bindings.production_base_url})` : ''}
) : null} {bindings && bindings.production_connected && bindings.production_base_url ? (