9 Commits

Author SHA1 Message Date
wonder e49b744385 feat: 新增参考材料后端支持
- 新增 SessionMaterial 模型
- 新增 builder_session_materials 表自动迁移
- BuilderSession 增加 Materials 字段
- CreateBuilderSession/UpdateBuilderSession 支持保存材料
- GetBuilderSession 支持加载材料
- DeleteBuilderSession 支持级联删除材料
- AssemblePrompt 支持组装材料内容到 Prompt
2026-06-26 17:26:27 +08:00
wonder 1bb3978c9a fix: 将生成 Prompt 中的章节标题自定义内容改为用户输入 2026-06-26 17:07:23 +08:00
wonder a1e4246bf4 feat: 在设置页新增系统标签管理面板,放开系统标签的 CRUD 限制
- 移除 tags.go 中 UpdateTag 和 DeleteTag 对系统标签的 403 限制
- 在 settings.html 新增「系统标签管理」卡片,支持:
  - 折叠浏览所有系统标签及其选项
  - 编辑标签名称和描述
  - 编辑、添加、删除标签选项
  - 删除整个标签(带二次确认)
- .gitignore 添加 prompt-generator 二进制文件
2026-06-26 16:26:10 +08:00
wonder b23ed28b88 fix: 优化生成 Prompt 的标题映射,移除技术术语
- 标签约束 → 约束
- 用户自定义内容 → 自定义内容
- 片段内容 → 参考片段
- 片段: xxx → xxx(去掉前缀)
- 智能建议补充 → 补充建议
2026-06-26 16:05:59 +08:00
wonder 1e3aa9b06b fix: 回退 DSN loc 为 Local,配合 tzdata 和 TZ 环境变量使用 2026-06-26 15:55:35 +08:00
wonder 7d717e30ce fix: 设置 MySQL 连接时区为 Asia/Shanghai 确保前端时间显示东八区 2026-06-26 15:48:40 +08:00
wonder 173d857dbb feat: structure view in dashboard and settings persistence
- Add GET /api/claude/sessions/{session_id}/builder API for structure view
- Load builder session tags and snippets by Claude session ID
- Implement structure view in dashboard: shows tag selections and snippet details
- Add LoadSettings to persist LLM config changes across restarts
- Settings are now loaded from database on startup

Co-Authored-By: Claude <noreply@anthropic.com>
2026-06-26 15:14:10 +08:00
wonder b7008afd29 fix: SPA routing and prompts table handling
- Add clean URL routing: /dashboard -> dashboard.html, /settings -> settings.html
- Add EnsurePromptsTable for dev environments where prompts table may not exist
- Fix nav links to use clean URLs instead of .html paths

Co-Authored-By: Claude <noreply@anthropic.com>
2026-06-26 15:08:12 +08:00
wonder 01ecdc8c23 feat: initialize project skeleton with Go backend, database, and config
- Go module with standard library + gorilla/sessions + mysql driver
- Config: env-based configuration with .env file support
- Database: MySQL connection with auto-migration for 6 tables
- Seed data: 12 system tags with options, 8 system snippets
- Auth: session cookie middleware
- Handlers: auth, tags, snippets, builder, claude, dashboard, suggestions, settings
- LLM: OpenAI-compatible client with 30s timeout
- Docker: Dockerfile + docker-compose.yml
- .env.example with all configuration options

Co-Authored-By: Claude <noreply@anthropic.com>
2026-06-26 14:58:15 +08:00