Skip to content

feat: add department staffing-hours report - #19

Merged
nooby6 merged 1 commit into
mainfrom
feat/staffing-hours-report
Oct 27, 2026
Merged

nooby6 merged 1 commit into
mainfrom
feat/staffing-hours-report

Conversation

@nooby6

@nooby6 nooby6 commented Oct 27, 2026

Copy link
Copy Markdown
Owner

Summary

  • Add authenticated GET /api/v1/reports/staffing-hours with startsAt and endsAt parameters.
  • Aggregate scheduled shift count, distinct employee count, and scheduled hours by department in one PostgreSQL query.
  • Clip each shift's hours to the requested window; exclude cancelled shifts and shifts outside the window; sort results by department.
  • Reject invalid time windows and document the endpoint.

Tests

  • Service mapping, empty-result and invalid-window unit tests.
  • MVC tests for authentication and response shape.
  • PostgreSQL integration test for overlap clipping, aggregation, cancelled shifts, and out-of-window shifts.

Closes #18. CI must pass before merge.

@nooby6
nooby6 merged commit 0397886 into main Oct 27, 2026
1 check passed
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.

feat: report scheduled staffing hours by department

1 participant