Files
msh-system/scripts/logs/agent-BUG-009-102338.log
scottpan 4be53dcd1b feat: 集成 KieAI 服务,移除 models-integration 子项目
- 添加 Gemini 2.5 Flash 对话接口(流式+非流式)
- 添加 NanoBanana 图像生成/编辑接口
- 添加 Sora2 视频生成接口(文生视频、图生视频、去水印)
- 移除 models-integration 子项目(功能已迁移至主后端)
- 新增测试文档和 Playwright E2E 配置
- 更新前端页面和 API 接口
- 更新后端配置和日志处理
2026-03-03 15:33:50 +08:00

25 lines
1.4 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
已按 BUG-009 要求处理,修改总结如下。
**1. Template 中的 Tab 与类型标签**
- **Tab 文案**:四个 Tab 的展示文字已是中文(推荐、最新、关注、热门),无需改。
- **Tab 内部值**`currentTab` 仍为 `recommend` / `latest` / `follow` / `hot`,用于 `switchTab` 和接口参数 `tab: this.currentTab`。按要求不改动接口逻辑,因此这些值保持英文,仅界面显示为中文。
- **帖子类型标签**`.type-tag` 和 `.meal-tag` 的文案都来自 `getMealTypeLabel(item.mealType)`,没有在模板里写死英文。
**2. 数据中的类型字段与 label 映射**
- `getMealTypeLabel` 中已有英文 → 中文映射breakfast→早餐、lunch→午餐、dinner→晚餐、snack→加餐、share→分享、checkin→打卡。
- 原先在未知类型时会 `return mealType`,可能把后端英文直接展示出来。
- **修改**:未知类型时的 fallback 从 `mealType` 改为 `'分享'`,保证所有展示的 label 都是中文。
**具体改动(仅一处)**
- 在 `getMealTypeLabel` 中,将
`return map[lower] != null ? map[lower] : mealType`
改为
`return map[lower] != null ? map[lower] : '分享'`
这样任意未在 map 中的 `mealType`(包括英文或其它值)在界面上都会显示为「分享」,不会出现英文。
路由与接口调用未做任何修改。