Skip to content

Events: deep link puzzle_add?competition=<uuid> and an "Add my time from this event" CTA on event and edition pages - #208

Merged
JanMikes merged 1 commit into
mainfrom
feat/event-add-time-deep-link
Aug 19, 2026
Merged

Events: deep link puzzle_add?competition=<uuid> and an "Add my time from this event" CTA on event and edition pages#208
JanMikes merged 1 commit into
mainfrom
feat/event-add-time-deep-link

Conversation

@JanMikes

Copy link
Copy Markdown
Member

Part 4 of 4 for #204 (after #205, #206, #207) — closes the loop from the events pages.

What

  • Deep linkGET /en/puzzle-add?competition=<uuid> pre-selects that competition in the "Competition / event" picker (the section auto-expands). Honoured only when the competition is publicly visible (IsCompetitionPubliclyVisible, the same rule the picker uses, so the link always lands on a real pre-selection) and the form is in speed-puzzling mode; anything else is ignored silently. A POST overwrites the data, so the prefill never leaks into a cleared submission.
  • CTA "Add my time from this event" on the event detail page (next to "I'm going") and on the edition detail page (next to registration/results), shown to signed-in players when the event is visible and has already started (CompetitionEvent::startsAfter()COALESCE(dateFrom, dateTo) by calendar day; undated = perpetual = always). No per-edition CTA on the series page — the edition page is one click away and carries its own.
  • Translation events.add_my_time (English, en fallback for other locales); README section extended.

Tests

+14: PuzzleAddControllerTest (prefill for a live standalone and for an edition → value set + section expanded; ignored for unapproved standalone, edition of an unapproved series, not-a-uuid, random uuid; ignored in relax mode), EventDetailControllerTest (CTA for logged-in on a live event, absent anonymous, absent on upcoming), new EditionDetailControllerTest (past edition shows CTA logged-in, not anonymous; upcoming edition none). Full gates green (cs, phpstan max, 2251 tests, schema:validate, prod warmup).

Closes #204

🤖 Generated with Claude Code

https://claude.ai/code/session_01QUegPi2i9SjwkcrNWyENnL

…rom this event" CTA on event and edition pages

The add-time form pre-selects a publicly visible competition passed as
?competition= (anything else is ignored silently; POST overwrites the
data). Event and edition detail pages show the CTA to signed-in players
once the event has started (undated = perpetual = always), so the link
always lands on a pre-selected picker. No per-edition CTA on the series
page.

Closes #204

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QUegPi2i9SjwkcrNWyENnL
@JanMikes
JanMikes merged commit dfea6bc into main Aug 19, 2026
5 checks passed
@JanMikes
JanMikes deleted the feat/event-add-time-deep-link branch August 19, 2026 19:14
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.

Add-time form: competitions/editions missing from the event picker (+ API PUT detaches events)

1 participant