Remove legacy settings secret migration

- Remove the super-admin one-time migration from browser local settings into backend AI and speech settings.

- Delete the migration-specific SystemSettings unit test that no longer matches the desired behavior.

- Restore feature, module, testing, and progress docs so settings secrets are documented as backend-managed only.
This commit is contained in:
2026-05-02 02:26:21 +08:00
parent 8e0332b3cf
commit 8de3a12dc1
6 changed files with 2 additions and 140 deletions

View File

@@ -38,14 +38,10 @@
系统通过后端 `/api/ai/models` 测试连接和获取模型列表,通过 `/api/ai/chat` 在报告编辑器中生成内容。后端读取全局共用 Provider Key 并代理 OpenAI 兼容 `/models``/chat/completions`,普通用户读取设置时不会拿到 AI Key。
从旧前端 mock 版本迁移时,如果超级管理员浏览器的 `localStorage.systemSettings` 中仍保留旧 AI Key而后端全局配置为空设置页会在读取后端配置后把本地旧密钥合并到当前设置并自动写入后端。该逻辑只用于迁移已有浏览器缓存源码、文档和 Docker 配置仍不内置真实密钥。
## 讯飞语音配置
`xfSpeechConfig` 保存讯飞 WebSocket IAT 所需的 APPID、APIKey 和 APISecret。报告编辑器只连接本系统 `/api/speech/iat`,由后端读取这些配置、生成讯飞鉴权 URL 并转发音频和识别结果。普通用户读取设置时不会拿到 APIKey/APISecret。
讯飞配置同样支持从旧本地 `xfSpeechConfig` 向后端 Settings API 做一次性迁移。迁移成功后,医生端语音听写只依赖后端代理和登录 Session。
## 默认模板
`defaultTemplate` 指向模板 ID。新建报告时如果当前用户可见该模板编辑器会自动加载对应模板内容否则回退到默认内置报告内容。