feat(cms): 案例/文章列表与详情改读 publishTime
配合后端拆出独立的 publish_time 列(见 ADR 0016)。 - 案例列表/详情、文章列表/详情统一取 publishTime,不再回退 createTime (createTime 是系统记录时间,运营没设过,展示它等于显示错误值) - 案例详情页标签由「项目时间」更正为「发布时间」,并补 dayjs 格式化 (原先直出 2026-09-23 19:06:37 完整时间戳) - server/utils/case.ts 废弃 projectTime,改为输出 publishTime - CaseItem 类型同步 仅改 template-07:其余 9 套模板的 CaseDetail 仍读已废弃的 projectTime, 因 CaseItem 带索引签名不会报编译错误,只会在换模板时静默显示创建时间。 该技术债已记入 docs/adr/0016 的「后果」一节,换模板前须先补这 9 套。
This commit is contained in:
@@ -17,7 +17,7 @@
|
||||
<NuxtLink :to="`/case/${item.id}`" class="block py-4 group">
|
||||
<div class="flex items-baseline gap-4">
|
||||
<span class="shrink-0 text-xs text-gray-400 tabular-nums">
|
||||
{{ formatDate(item.projectTime || item.createTime) }}
|
||||
{{ formatDate(item.publishTime) }}
|
||||
</span>
|
||||
<h2 class="flex-1 min-w-0 text-base text-gray-900 truncate group-hover:text-blue-600 transition-colors">
|
||||
{{ item.title }}
|
||||
|
||||
Reference in New Issue
Block a user