Jersey email: add division filter + persist template #243
Labels
No labels
domain:backend
domain:devops
domain:frontend
status:approved
status:in-progress
status:needs-fix
status:qa
type:bug
type:devops
type:feature
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
ldraney/basketball-api#243
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Type
Feature
Lineage
Decomposed from original #243. Code-only scope. Ops/validation split to westside-landing#182.
Repo
forgejo_admin/basketball-apiUser Story
As Marcus (admin)
I want to filter jersey reminder emails by division
So that I can target boys or girls separately
Context
38 of 39 boys have never interacted with the jersey page. The jersey-reminder endpoint currently sends to ALL parents with tokens — no division filter, no way to exclude those who already ordered. Template was hotfixed via ConfigMap but needs to be persisted in the repo for CI/CD.
File Targets
Files the agent should modify or create:
src/basketball_api/routes/admin.py— adddivisionandexclude_orderedquery params toPOST /admin/email/jersey-remindersrc/basketball_api/services/email.py— update plain-text fallback copy with deadline messaging, update subject lineemail-templates/jersey-reminder.html— commit current ConfigMap template to repotests/test_jersey_reminder.py— add tests for division filter and exclude_ordered logicFiles the agent should NOT touch:
src/basketball_api/routes/checkout.pysrc/basketball_api/services/jersey_sync.pysrc/basketball_api/routes/webhooks.pyAcceptance Criteria
POST /admin/email/jersey-reminder?division=boyssends only to parents with boys-division playersPOST /admin/email/jersey-reminder?exclude_ordered=trueskips parents whose players havejersey_option IS NOT NULLJersey Orders Open — Westside Kings & Queensemail-templates/jersey-reminder.htmlcommitted to repoTest Expectations
divisionparam filters parents to matching division onlyexclude_orderedparam skips parents with ordered playerspytest tests/test_jersey_reminder.py -vConstraints
admin.py(query params, response models)email-templates/jersey-reminder.htmlat repo rootChecklist
Related
project-westside-basketballwestside-landing#180— deadline bug (blocker, must deploy first)westside-landing#182— ops/validation ticket (depends on this)Scope Review: NEEDS_REFINEMENT
Review note:
review-660-2026-03-2912 acceptance criteria across mixed code + operational concerns exceeds single-agent scope.
division/exclude_orderedparams, persist template, unit tests (7 automatable AC); (2) ops — E2E validation, test send to Marcus, production send to boys (5 manual AC)email-templates/directory does not exist in repo — agent must create directory + fileJersey deadline email: validate full flow + send to boysto Jersey email: add division filter + persist templateScope review: NEEDS_REFINEMENT → DECOMPOSED
Review
review-660-2026-03-29flagged 12 AC mixing code + ops concerns. Split into:Issue body updated with refined code-only scope per consolidated spec convention.
Scope Review: READY (re-review)
Review note:
review-660-2026-03-29Decomposition addressed: code-only scope retained here (7 AC), ops/validation split to westside-landing#182. All file targets verified, traceability complete, data model confirmed.
One minor fix before dispatch:
[BODY]Related section referenceswestside-landing#181(closed unrelated PR) — should bewestside-landing#182(the ops ticket).