Commit Graph

7 Commits

Author SHA1 Message Date
yw1573 2a3dc99a7a refactor: remove showFile API for Docker compatibility
Docker 容器内无法调用宿主机文件管理器,移除 showFile 接口:
- 移除后端 showFile 路由和处理函数
- 移除前端 showFile 调用和"打开文件位置"按钮
- 移除 opening 状态和 FolderSVG 组件

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-09 18:11:56 +08:00
yw1573 c8ee9685b9 perf: optimize batch task creation with single transaction
批量创建任务使用单事务数据库插入,显著提升性能。
移除任务列表的批量取消/删除进度显示(批处理接口无意义)。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-09 17:24:06 +08:00
yw1573 a0ef988bd5 fix: resolve critical issues and improve task management
- Fix path traversal vulnerability in downloadVideo handler by adding
  download directory whitelist validation
- Add graceful shutdown with signal handling for task persistence
- Fix division by zero panic in progressBar.percent() when total <= 0
- Add GetDB() function that returns error instead of using log.Fatal
- Change deleteTask to only remove database records, preserve downloaded files
- Add paused status for interrupted tasks on shutdown

Co-Authored-By: Claude
2026-04-09 16:51:22 +08:00
yw1573 e8f71b04ac feat(task): add batch delete and cancel API support
支持批量删除和取消任务的接口:
- deleteTask 接口支持 POST 方式传入 ids 数组
- cancelTask 接口支持 POST 方式传入 ids 数组
- 前端批量操作改为调用批量接口,减少请求数量

Co-Authored-By: AI
2026-04-07 17:38:52 +08:00
yw1573 81df437b2c feat: add task cancellation support
- Add CancelTask function to cancel running/waiting tasks
- Add /api/cancelTask endpoint
- Add cancel button in task list for running/waiting tasks
- Check cancellation status during download and merge operations

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-07 16:40:27 +08:00
yw1573 1b23d813a8 perf: optimize createTask by moving GetCurrentFolder outside loop
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-07 16:16:49 +08:00
yw1573 dd8eaef97d refactor: restructure project to standard Go layout
- Reorganize code into cmd/bilidown and internal/ packages
- Rename client/ to web/ for frontend source
- Remove systray dependency for headless web service
- Embed static files into binary using go:embed
- Update import paths to use internal/ prefix
- Update .gitignore with common patterns

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-02 17:21:49 +08:00