日志:R25 首页AI脚本卡片评分徽章(listRecentScripts 关联复盘总分)

This commit is contained in:
maogeigei committed 2026-09-03 15:32:36 +08:00
1 parent 4f4e126e61
commit 555cd693cb
1 file changed
+8
+8
View File
@@ -187,3 +187,11 @@
- data-pages.js RANK_TABS 第三字段 tip 动态拼 title;app.js 首页 preview 两 tab 静态 title;ICON_PATHS 'info'、.rank-tab-info CSS 全部删净(0 残留)
- 教训沉淀:图标方案两度反复(图标→气泡→图标→title),根因=未在动工前确认交互形态;今后 UI 交互类需求先 1 问确认(图标+tooltip / 纯悬停)再改
- git 2909220(56a3ea5..2909220,含 97dae59 日志提交);index.html 版本 ?v=20260903f
## R25 首页 AI脚本卡片右下角显示脚本评分(09-03)
- 需求:AI 脚本若有对应评分 → 显示在卡片右下角;无评分不显示
- 后端 dsh-data.js listRecentScripts 增加标量子查询:取该 rewrite 最新一条已完成的 AI 复盘总分(script_review type='ai' AND rewrite_id=r.id AND status='done' AND total 非空 ORDER BY id DESC LIMIT 1)AS score,无复盘=null
- 前端 app.js loadRecentScripts:卡片底部改 .recent-card-foot 双栏(meta 左 flex:1 / 徽章右),有分渲染 .recent-card-score 圆角徽章「评分 X」,配色同诊断页 scoreColor(≥75 绿 #3a9e6d / ≥60 橙 #d99a2b / <60 红 #d9534f,hex+1a 透明底);无分(null/''/undefined)不输出
- CSS:meta 的 width:100%/margin-top:auto 迁到 .recent-card-foot(底部行整行推底)
- 验证:工作台库 mcn-plugin.db(**非 ~/.dsh/mcn-plugin.db**,两库隔离)26 done 脚本 16 无评分;API limit=20 → 有分10/无分10,null 双路径确认
- **重启服务才生效**(dsh-data.js 后端模块,旧 PID 5500→新 23268,taskkill 单斜杠);git 436cfb3;版本 ?v=20260903g