Skip to content

Feature/reservationv2#4

Open
yangl0610 wants to merge 4 commits intoQSCTech:mainfrom
yangl0610:feature/Reservationv2
Open

Feature/reservationv2#4
yangl0610 wants to merge 4 commits intoQSCTech:mainfrom
yangl0610:feature/Reservationv2

Conversation

@yangl0610
Copy link
Copy Markdown

  • 实现 TriggerReservation:直接使用存储的 slot
    context 调用 ReserveV2,无需重新查询 TYYS dayInfo
  • 新增 /internal/tasks/reservation-trigger
    内部端点供调度器触发预约
  • Submit 接口立即返回 submitting 状态,后台
    goroutine 异步执行 TYYS 预约并更新最终状态
  • 修复 ListVenues 静默吞错问题,TYYS 失败时返回
    502
  • ReservationRepository 新增 GetByID /
    Update
  • main.go 接入 TYYSPythonCaptchaSolver

yangl0610 and others added 4 commits April 20, 2026 12:56
- ListVenues / ListSlots 对接 TYYS API
- 修复数值类型 ID 解析问题
- OpenAPI 补充可选值文档

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
将 ReservationSlot 拆分为 ReservationSlotGroup(按时段聚合)和
ReservationSpaceSlot(具体场地),提交/预览/记录接口新增 time_id、
token、week_start_date 字段,移除冗余的 venue_id;test.go 加入
.gitignore 作为本地调试脚本不纳入版本管理。

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
… endpoint

- Add TriggerReservation service method: reads stored slot context and calls
  ReserveV2 without re-querying TYYS dayInfo; updates status to success/failed
- Add /internal/tasks/reservation-trigger endpoint for scheduler use
- Fire background goroutine in Submit when TYYS window is already open;
  returns submitting immediately, goroutine updates final status
- Fix ListVenues to propagate TYYS errors instead of silently returning nil
- Add GetByID and Update to ReservationRepository
- Wire TYYSPythonCaptchaSolver into ReservationService constructor

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant