Review: Add jersey order card to player profile page

review-westside-landing-197 Doc

review needs-refinement

Verdict: NEEDS_REFINEMENT

Ticket is well-written and nearly ready, but has two blocking issues that prevent moving to todo.

Template Completeness

  • ✅ Type: Feature
  • ✅ Lineage: References parent spike #196, dependencies, story WS-S18
  • ✅ Repo: forgejo_admin/westside-landing
  • ✅ User Story: Clear as/want/so-that
  • ✅ Context: Explains current state and gap
  • ✅ File Targets: Specifies modify and do-not-touch files
  • ✅ Acceptance Criteria: 5 concrete when/then conditions
  • ✅ Test Expectations: Manual tests + build check
  • ✅ Constraints: Card style, permissions, backend dependency noted
  • ✅ Checklist: Present
  • ✅ Related: Project and parent issue linked

File Target Verification

  • src/routes/(app)/players/[id]/+page.svelte exists (575 lines). Insertion point at line ~495 is correct -- sits between team/coach card end and payment card start.
  • .info-card CSS pattern is used extensively (10+ instances in this file).
  • ✅ No jersey-related code exists on this page yet (clean slate).
  • ✅ Do-not-touch files confirmed to exist: jersey/+page.svelte and checkout/+page.svelte.

Traceability

  • ✅ Board item #695 exists with labels: type:feature,story:WS-S18,arch:westside-app
  • ❌ Story note ws-s18 does NOT exist in pal-e-docs (404). Needs creation.
  • ❌ Forgejo issue #197 has NO labels. Should have at minimum story:WS-S18 and type:feature.

Dependency Check

  • BLOCKING: basketball-api#256 (Add player_id param to jersey/checkout endpoints) -- open, backlog
  • BLOCKING: westside-landing#198 (Update jersey/checkout pages to support session auth) -- open, backlog
  • Both dependencies are in backlog with no labels set on the Forgejo issues.
  • The ticket itself states: "Backend must expose jersey fields in PlayerProfileResponse first"
  • Board items for both deps (#694 for #256, #696 for #198) are also in backlog.

Decomposition Assessment

  • ✅ Frontend change is well-scoped: 1 file, 1 card component, ~30-40 lines of Svelte
  • Ambiguous backend scope: The ticket says "PlayerProfileResponse in basketball-api needs jersey fields added (this may be a separate micro-ticket or done inline)." This must be resolved. Either:

Acceptance Criteria Quality

  • ✅ Five concrete when/then conditions
  • ✅ Covers: no-order state, order button navigation, paid state display, coach visibility, unauthenticated visibility
  • ✅ Permission model clearly stated (isOwner or isAdmin only)

Required Fixes Before Moving to Todo

  • Resolve backend scope ambiguity: Decide whether the PlayerProfileResponse jersey fields addition is a separate ticket or a prerequisite. If separate, create it and add it as an explicit dependency. If prerequisite, list basketball-api#[new-number] in the Lineage section.
  • Create story note WS-S18 in pal-e-docs (or confirm it maps to an existing story).
  • Add Forgejo labels to issue #197: At minimum story:WS-S18, type:feature.
  • Add depends-on labels to board item #695: Should include depends:basketball-api-256,depends:westside-landing-198 to make blocking dependencies visible on the board.
  • Clarify execution order: This ticket cannot be dispatched until its dependencies ship. The Lineage section should explicitly state "Blocked by: basketball-api#256, westside-landing#198" rather than the current softer "Depends on" language.

Recommendations

  • The ticket quality is high -- template is complete, acceptance criteria are concrete, file targets are verified. The blocking issues are all process/traceability gaps, not content gaps.
  • Once the 5 fixes above are applied, this ticket is ready for todo.