feat(phase2): 剪辑计划API路径从/edit-plans迁移到/template-editors #645

Merged
auto-approve-bot merged 1 commits from feat/phase2-migrate-edit-plans-to-template-editors into develop 2026-07-20 19:06:09 +08:00
Owner

变更内容

剪辑计划架构整合 Phase 2 — 前端 API 路径迁移

修改文件

  • apps/web/src/api/editPlans.ts: 22个API端点路径全部从 /edit-plans/* 改为 /template-editors/*
  • apps/web/src/pages/generate/GeneratePage.tsx: 直接调用 apiClient 的 generation-status 改为使用 getGenerationStatus 函数,删除未用的 apiClient import

范围

  • 所有编辑器相关的后端请求(生成、片段CRUD、AI推荐、封面生成等)
  • 智能剪辑页面的生成状态轮询

备注

  • 旧路径后端仍兼容(deprecated标记),前端尽快切完
  • 字段名(source_edit_plan_id等)保持不变
  • 前端路由 /app/edit-plans 暂未动,后续 Phase 3 清理
## 变更内容 剪辑计划架构整合 Phase 2 — 前端 API 路径迁移 ### 修改文件 - `apps/web/src/api/editPlans.ts`: 22个API端点路径全部从 `/edit-plans/*` 改为 `/template-editors/*` - `apps/web/src/pages/generate/GeneratePage.tsx`: 直接调用 `apiClient` 的 generation-status 改为使用 `getGenerationStatus` 函数,删除未用的 `apiClient` import ### 范围 - 所有编辑器相关的后端请求(生成、片段CRUD、AI推荐、封面生成等) - 智能剪辑页面的生成状态轮询 ### 备注 - 旧路径后端仍兼容(deprecated标记),前端尽快切完 - 字段名(source_edit_plan_id等)保持不变 - 前端路由 /app/edit-plans 暂未动,后续 Phase 3 清理

🚀 预览环境已部署

项目 详情
PR号 #645
预览链接 https://pr-645.preview.xiaoxiajianji.com
API环境 staging

💡 预览环境使用 staging API 数据,请勿在预览环境中操作重要数据。

🔄 每次提交新代码后预览环境会自动更新。

🗑️ PR 关闭或合并后,预览环境会自动清理。

🚀 **预览环境已部署** | 项目 | 详情 | |------|------| | PR号 | #645 | | 预览链接 | [https://pr-645.preview.xiaoxiajianji.com](https://pr-645.preview.xiaoxiajianji.com) | | API环境 | staging | > 💡 预览环境使用 staging API 数据,请勿在预览环境中操作重要数据。 > > 🔄 每次提交新代码后预览环境会自动更新。 > > 🗑️ PR 关闭或合并后,预览环境会自动清理。
xiaoxia force-pushed feat/phase2-migrate-edit-plans-to-template-editors from cc00428019 to 95a7006026 2026-07-20 18:32:37 +08:00 Compare
xiaoxia force-pushed feat/phase2-migrate-edit-plans-to-template-editors from 95a7006026 to b63ed41f51 2026-07-20 18:47:53 +08:00 Compare
xiaoxia force-pushed feat/phase2-migrate-edit-plans-to-template-editors from b63ed41f51 to 25f0681525 2026-07-20 18:53:41 +08:00 Compare
xiaoxia added 1 commit 2026-07-20 18:57:34 +08:00
feat(phase2): 剪辑计划API路径从/edit-plans迁移到/template-editors
CI/CD Pipeline / Check if frontend-only change (pull_request) Successful in 12s
CI/CD Pipeline / Build Staging API Image (pull_request) Has been skipped
CI/CD Pipeline / Build Staging Web Image (pull_request) Has been skipped
CI/CD Pipeline / Build Staging Worker Image (pull_request) Has been skipped
CI/CD Pipeline / Build Production API Image (pull_request) Has been skipped
CI/CD Pipeline / Build Production Web Image (pull_request) Has been skipped
CI/CD Pipeline / Build Production Worker Image (pull_request) Has been skipped
CI/CD Pipeline / Deploy Staging (Watchtower auto-deploy) (pull_request) Has been skipped
CI/CD Pipeline / Deploy Production (pull_request) Has been skipped
CI/CD Pipeline / Staging E2E Tests (pull_request) Has been skipped
CI/CD Pipeline / Staging API Integration Tests (pull_request) Has been skipped
CI/CD Pipeline / ACR Image Cleanup (pull_request) Has been skipped
CI/CD Pipeline / Production Browser E2E (pull_request) Has been skipped
Preview Deploy / Deploy Preview Environment (pull_request) Successful in 1m38s
AI Code Review / AI Code Review (pull_request) Successful in 2m43s
CI/CD Pipeline / Validate Code Quality And Tests (pull_request) Has been skipped
CI/CD Pipeline / Unit Tests (pull_request) Has been skipped
CI/CD Pipeline / Integration Tests (pull_request) Has been skipped
CI/CD Pipeline / Frontend Lint (pull_request) Successful in 7m4s
PR Automation / Auto Approve on CI Green (pull_request) Successful in 6m54s
PR Automation / Auto Merge on CI Green + Approved (pull_request) Successful in 7m34s
Preview Cleanup / Cleanup Preview Environment (pull_request) Successful in 14s
CI/CD Pipeline / Frontend Unit Tests (pull_request) Successful in 8m4s
21fc3f3b45
- api/editPlans.ts: 22个API端点路径全部从/edit-plans/*改为/template-editors/*
- GeneratePage.tsx: 直接调用apiClient的generation-status改为使用getGenerationStatus函数,删除未用的apiClient import
xiaoxia force-pushed feat/phase2-migrate-edit-plans-to-template-editors from 25f0681525 to 21fc3f3b45 2026-07-20 18:57:34 +08:00 Compare
Collaborator

代码审查结果 - PR #645

⚠️ 问题(1个需要修改)

  1. apps/web/src/api/editPlans.ts (文件权限): 源代码文件(.ts)被修改为可执行权限(mode 100755)。源文件通常不需要执行权限,这通常是由于开发者本地 git 配置(如 core.fileMode)导致的误操作。建议将文件权限改回 100644,以保持代码仓库的规范性。

💡 建议(1个可选)

  1. apps/web/src/api/editPlans.ts (接口定义): GenerationStatusResponse 接口中同时增加了 error_messageerrormessage 三个可能用于描述错误或状态的字段。建议明确区分这三个字段的业务含义(例如:message 用于成功提示,error 用于错误码,error_message 用于详情),或者统一命名,避免前端调用时产生歧义。

格式检查通过 | 逻辑审查需修改 | 建议关注性能


🤖 由 AI 代码审查机器人自动生成 | 2026-07-20 19:00:49 | 模型:

## 代码审查结果 - PR #645 ### ⚠️ 问题(1个需要修改) 1. **apps/web/src/api/editPlans.ts (文件权限)**: 源代码文件(.ts)被修改为可执行权限(mode 100755)。源文件通常不需要执行权限,这通常是由于开发者本地 git 配置(如 `core.fileMode`)导致的误操作。建议将文件权限改回 100644,以保持代码仓库的规范性。 ### 💡 建议(1个可选) 1. **apps/web/src/api/editPlans.ts (接口定义)**: `GenerationStatusResponse` 接口中同时增加了 `error_message`、`error` 和 `message` 三个可能用于描述错误或状态的字段。建议明确区分这三个字段的业务含义(例如:`message` 用于成功提示,`error` 用于错误码,`error_message` 用于详情),或者统一命名,避免前端调用时产生歧义。 --- ❌ 格式检查通过 | ✅ 逻辑审查需修改 | ✅ 建议关注性能 --- <sub>🤖 由 AI 代码审查机器人自动生成 | 2026-07-20 19:00:49 | 模型: </sub> <!-- AI_CODE_REVIEW_AUTO_COMMENT -->
auto-approve-bot approved these changes 2026-07-20 19:05:01 +08:00
auto-approve-bot left a comment
Collaborator

CI全绿,自动审批通过。

CI全绿,自动审批通过。
auto-approve-bot approved these changes 2026-07-20 19:05:02 +08:00
auto-approve-bot left a comment
Collaborator

CI全绿,自动审批通过。

CI全绿,自动审批通过。
auto-approve-bot merged commit 151ec6e3d5 into develop 2026-07-20 19:06:09 +08:00
auto-approve-bot deleted branch feat/phase2-migrate-edit-plans-to-template-editors 2026-07-20 19:06:09 +08:00

🗑️ 预览环境已清理

PR #645 已关闭或合并,对应的预览环境已被清理。

如有需要,可以重新打开 PR 来重新生成预览环境。

🗑️ **预览环境已清理** PR #645 已关闭或合并,对应的预览环境已被清理。 > 如有需要,可以重新打开 PR 来重新生成预览环境。
Sign in to join this conversation.