Christ
|
45f895d0c4
|
完善续期通知与前端界面
|
2026-07-10 10:38:25 +08:00 |
|
Christ
|
25419c027f
|
修复登录续期与数据库验证回归
- 修复密码登录、续期和账号编辑链路的边界问题
- 补齐 dbverify、后端与前端单测
- 同步 Docker 与前端构建产物
|
2026-07-09 16:08:16 +08:00 |
|
Christ
|
3d37ff7917
|
chore: checkpoint repaired xianyu-go baseline
|
2026-07-08 03:46:15 +08:00 |
|
 ChristandClaude Opus 4.8
|
0fa5d6617c
|
refactor(db): 阶段A - driver 抽象 + SQLite 保持工作
- db.Open 改为接受 URL(sqlite:// mysql:// postgres://),返回 (db, dialect, err)
- 向后兼容:不含 scheme 的路径仍按 SQLite 文件处理
- migration 移到 migrations/sqlite/ 子目录,embed 包含三个方言目录
- Migrate 按方言选择子目录 + goose dialect
- Store 加 Dialect 字段,NewStore(db, dialect)
- cmd/server 加 -db-url 和 DATABASE_URL 环境变量(优先级:env > -db-url > -db)
- cmd/init-admin 同步支持 URL
- 新增依赖 pgx/v5、go-sql-driver/mysql
- mysql/postgres migration 目录暂为 SQLite 副本占位,阶段B/C 替换
- 所有测试调用方更新为新签名
验证:现有测试全过(SQLite 回归),SQLite 行为不变
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
2026-07-06 12:35:01 +08:00 |
|
 ChristandClaude Opus 4.8
|
3f7954af84
|
feat: token 保活 + 通知系统 + 批量铺货 + 卡密批量 + 前端路由与样式对齐
后端
- token 刷新:session 过期立即触发密码登录兜底(不再空跑5次冷却);
FAIL_SYS_SESSION_EXPIRED 识别为凭证失效;token 刷新成功日志;
在线定时刷新 token 间隔从 1h 调整为 15min,持续续期 cookie
- QR 登录:修复自动验证成功状态被 EXPIRED 覆盖的竞态(前端拿不到 cookie)
- 通知系统:Notifier 加 NotifyAccountAlert/SendToChannel;engine Handler
加 OnAccountAlert(warn/critical/风控三触发点);handlerAdapter 接 notifier;
通知渠道测试发送端点 POST /notification-channels/{id}/test;
NotificationChannelRow 加 json tag 修复前端读不到字段
- 卡密批量:POST /cards/batch 批量创建卡密组;POST /cards/{id}/append-data
往 data 组充卡密;DB AppendBatchData
- 通知渠道启用切换修复(全量更新避免 type CHECK 约束报错)
前端
- history 路由(/app/ 前缀避开 API 冲突,刷新不丢位置,popstate 同步)
- 通知设置页:渠道管理 + 账号绑定 + 配置指南 + SMTP(从系统设置移入)
- 卡密批量导入弹窗(批量建组 + 单组充卡密)
- 商品卡片缩小约 2/3;Rules/Notifications 头部样式对齐标准页
- 初始化提示按 OS 区分命令(Windows/macOS)
- updateChannel 全量更新修复启用切换失败
文档
- docs/批量铺货使用文档.md(给铺货 agent 的资料包准备规格)
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
2026-07-06 12:27:37 +08:00 |
|
 ChristandClaude Opus 4.8
|
3b4188c68c
|
feat: 优雅停机 + notify 通知触发接线
优雅停机:
- account.Manager 新增 StopAll(),先收集 cookieID 再逐个停,避免持锁等 goroutine
- cmd/server 在 srv.Run 返回后(正常+出错两路径)调 mgr.StopAll() + bm.Close()
- 修掉 automation.New 被构造两次的写法(先建 adapter→mgr→autoCenter→回填)
notify 接线(此前 notify 包写好但从未被调用,配置的渠道不会触发):
- automation.Center 加 Notifier 接口 + SetNotifier,executeRule 收尾按
成功(sent>0)/失败发通知,无匹配规则不刷屏
- main.go 注入 notify.Notifier 到 Center 和 Server
- manualShipOrders 的 full_delivery 与 status_only 两分支成功/失败都发通知
- 新增 3 个 automation 测试覆盖成功/失败/无规则通知路径
- 新增 account.TestManagerStopAll 覆盖 StopAll(-race 通过)
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
2026-06-30 21:40:34 +08:00 |
|
Christ
|
074554a6de
|
Initial xianyu-go repository
|
2026-06-28 11:54:39 +08:00 |
|