feat: enhance weekly report and realtime notifications
Weekly Report (fix-weekly-report): - Remove 5-task limit, show all tasks per category - Add blocked tasks with blocker_reason and blocked_since - Add next week tasks (due in coming week) - Add assignee_name, completed_at, days_overdue to task details - Frontend collapsible sections for each task category - 8 new tests for enhanced report content Realtime Notifications (fix-realtime-notifications): - SQLAlchemy event-based notification publishing - Redis Pub/Sub for multi-process broadcast - Fix soft rollback handler stacking issue - Fix ping scheduling drift (send immediately when interval expires) - Frontend NotificationContext with WebSocket reconnection Spec Fixes: - Add missing ## Purpose sections to 5 specs 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,38 @@
|
||||
## MODIFIED Requirements
|
||||
|
||||
### Requirement: Automated Weekly Report
|
||||
系統 SHALL 每週五下午 4:00 自動彙整完整任務清單發送給主管。
|
||||
|
||||
#### Scenario: 週報內容完整清單
|
||||
- **GIVEN** 週報生成中
|
||||
- **WHEN** 系統彙整資料
|
||||
- **THEN** 週報包含各專案的:
|
||||
- 本週已完成任務清單(含 completed_at, assignee_name)
|
||||
- 進行中任務清單(含 assignee_name, due_date)
|
||||
- 逾期任務警示(含 due_date, days_overdue)
|
||||
- 阻礙中任務清單(含 blocker_reason, blocked_since)
|
||||
- 下週預計完成任務(含 due_date, assignee_name)
|
||||
- **AND** 不設任務數量上限
|
||||
|
||||
#### Scenario: 阻礙任務識別
|
||||
- **GIVEN** 任務有未解除的 Blocker 記錄
|
||||
- **WHEN** 週報查詢阻礙任務
|
||||
- **THEN** 系統查詢 Blocker 表 resolved_at IS NULL 的任務
|
||||
- **AND** 顯示阻礙原因與開始時間
|
||||
|
||||
#### Scenario: 下週預計任務
|
||||
- **GIVEN** 任務的 due_date 在下週範圍內
|
||||
- **WHEN** 週報查詢下週預計任務
|
||||
- **THEN** 系統篩選 due_date >= 下週一 且 < 下週日
|
||||
- **AND** 排除已完成狀態的任務
|
||||
|
||||
## MODIFIED Technical Notes
|
||||
|
||||
- 週報 content JSON 結構擴充:
|
||||
- summary: 包含 blocked_count, next_week_count
|
||||
- projects[].completed_tasks: 無數量限制,含 completed_at, assignee_name
|
||||
- projects[].in_progress_tasks: 新增欄位
|
||||
- projects[].blocked_tasks: 新增欄位,含 blocker_reason, blocked_since
|
||||
- projects[].next_week_tasks: 新增欄位,含 due_date, assignee_name
|
||||
- 阻礙任務透過 Blocker 表 subquery 查詢
|
||||
- 下週計算以本週結束後 7 天為範圍
|
||||
Reference in New Issue
Block a user