feat: 内容数据迁移至数据库,合规审查全链路打通
- 文章 HTML 存储从文件系统迁移至 articles 表,删除 releases 目录 - 合规审查从 DB 读取 HTML,审查结果写回 DB,通过后自动推进至待发布 - 新增 todayCount 筛选按钮,与系统概览统计数据一致 - 全屏预览修复:提升 z-index 超过侧边栏,添加退出全屏/关闭按钮 - 统一 '优化' → '审查' 命名,消除前后端术语不一致 - 调度器创作完成后自动触发审查(生成 → 审查 → 待发布) - 清理旧备份/调试文件、过期大纲和研究笔记
This commit is contained in:
+10
-7
@@ -1,19 +1,22 @@
|
||||
#!/usr/bin/env python3
|
||||
import json
|
||||
import sys
|
||||
from collections import Counter
|
||||
from pathlib import Path
|
||||
sys.path.insert(0, str(Path(__file__).parent.parent))
|
||||
from db_helper import export_topics_to_json
|
||||
|
||||
with open('automation/data/sustainability_topics.json', 'r', encoding='utf-8') as f:
|
||||
data = json.load(f)
|
||||
topics = export_topics_to_json()
|
||||
|
||||
print('=== 选题库状态 ===')
|
||||
print(f'总选题数: {len(data)}')
|
||||
print(f'字段: {list(data[0].keys())}')
|
||||
print(f'总选题数: {len(topics)}')
|
||||
if topics:
|
||||
print(f'字段: {list(topics[0].keys())}')
|
||||
|
||||
print('\n状态分布:')
|
||||
status_counts = Counter(t.get('status', '<无>') for t in data)
|
||||
status_counts = Counter(t.get('status', '<无>') for t in topics)
|
||||
for s, c in sorted(status_counts.items()):
|
||||
print(f' {s}: {c} 个')
|
||||
|
||||
print('\n各状态详情:')
|
||||
for t in data:
|
||||
for t in topics:
|
||||
print(f"{t['id']}: {t['title'][:40]:40} | 状态: {t.get('status', '?'):6} | 优先级: {t.get('priority_score', '-')}")
|
||||
|
||||
Reference in New Issue
Block a user