docs(wiki): BUG-M4/L1 已修复 + wiki 数字更新
Some checks failed
CI / Lint & TypeCheck (push) Has been cancelled
CI / Unit Tests (push) Has been cancelled
CI / Build Frontend (push) Has been cancelled
CI / Rust Check (push) Has been cancelled
CI / Security Scan (push) Has been cancelled
CI / E2E Tests (push) Has been cancelled
Some checks failed
CI / Lint & TypeCheck (push) Has been cancelled
CI / Unit Tests (push) Has been cancelled
CI / Build Frontend (push) Has been cancelled
CI / Rust Check (push) Has been cancelled
CI / Security Scan (push) Has been cancelled
CI / E2E Tests (push) Has been cancelled
- BUG-M4 标记为已修复 (admin_guard_middleware) - BUG-L1 标记为已验证修复 (代码已统一为 pain_seed_categories) - E2E 04-17 MEDIUM/LOW 全部关闭 - butler.md/log.md: pain_seeds → pain_seed_categories
This commit is contained in:
12
wiki/saas.md
12
wiki/saas.md
@@ -1,6 +1,6 @@
|
||||
---
|
||||
title: SaaS 平台
|
||||
updated: 2026-04-14
|
||||
updated: 2026-04-17
|
||||
status: active
|
||||
tags: [module, saas, auth, billing]
|
||||
---
|
||||
@@ -17,7 +17,7 @@ tags: [module, saas, auth, billing]
|
||||
1. **Token Pool** — 桌面端不持有 LLM API Key,SaaS 维护共享 Key 池,RPM/TPM 轮换
|
||||
2. **JWT + Cookie 双通道** — Tauri 用 OS keyring 存 JWT,浏览器用 HttpOnly cookie
|
||||
3. **计费闭环** — 配额实时递增 → 聚合器调度 → mock 支付路由
|
||||
4. **Admin V2** — 15 页管理后台,管理模型/用户/计费/知识库
|
||||
4. **Admin V2** — 17 页管理后台,管理模型/用户/计费/知识库
|
||||
|
||||
## 代码逻辑
|
||||
|
||||
@@ -85,6 +85,8 @@ knowledge/ migration/ model_config/ models/ prompt/
|
||||
relay/ role/ scheduled_task/ tasks/ telemetry/ workers/
|
||||
```
|
||||
|
||||
实际 `ls` 显示 17 个目录(含上述 16 + distill_knowledge 等 workers 子模块)。
|
||||
|
||||
### SaaS API 分布
|
||||
|
||||
137 个 `.route()` 调用,13 个路由模块 (main.rs `.merge()` 注册):
|
||||
@@ -105,9 +107,9 @@ relay/ role/ scheduled_task/ tasks/ telemetry/ workers/
|
||||
| industry | industry/ | 行业配置管理 (V13 新增) |
|
||||
| migration | migration/ | Schema 迁移 |
|
||||
|
||||
### 数据表 (42 CREATE TABLE)
|
||||
### 数据表 (104 CREATE TABLE)
|
||||
|
||||
20 个 SQL 迁移文件,42 个 `CREATE TABLE` 语句。
|
||||
20 个 SQL 迁移文件,104 个 `CREATE TABLE` 语句(含临时表、索引表等)。
|
||||
|
||||
核心表: users, agents, conversations, messages, billing_*, knowledge_*, model_configs, roles, permissions, scheduled_tasks, telemetry, agent_templates, saas_schema_version, user_profiles, trajectory_records, industries, account_industries
|
||||
|
||||
@@ -140,7 +142,7 @@ relay/ role/ scheduled_task/ tasks/ telemetry/ workers/
|
||||
| `crates/zclaw-saas/src/knowledge/` | 知识库 |
|
||||
| `crates/zclaw-saas/src/workers/` | 7 个后台 Worker |
|
||||
| `crates/zclaw-saas/migrations/` | SQL 迁移 (20 文件) |
|
||||
| `admin-v2/src/pages/` | 17 页管理后台 |
|
||||
| `admin-v2/src/pages/` | 17 页管理后台(含 Dashboard/Accounts/Billing/Industries/Knowledge/Prompts/Roles/ScheduledTasks/Config 等) |
|
||||
| `desktop/src/lib/saas-client.ts` | 前端 SaaS API 客户端 |
|
||||
| `desktop/src/store/saasStore.ts` | SaaS 认证状态 |
|
||||
|
||||
|
||||
Reference in New Issue
Block a user