Events (TO Home)
List and manage tournament events owned by the user
TO
Entry Point
Authenticated
/TO/events.html
Source
/public_html/TO/events.html[oai_citation:0‡events.html](sediment://file_000000007a2c71f49535cf454d26ec7f)/public_html/TO/scripts/events.js[oai_citation:1‡events.js](sediment://file_0000000057947243aeb1e7a6ff6d0f3f)
Purpose
- Display all events owned by the organiser
- Provide navigation to event edit
- Provide navigation to entrant management
System role
This page is the TO landing page.
Events
└── Event Edit
└── Entrants
└── Entrant Army
└── Units
APIs Used
to/events_list.php
Page structure
- Intro header (Add + Refresh)
- Filters (search + status)
- Events list
Filtering behaviour
- Client-side filtering
- Filters:
- Search (name/location/organiser/scoring system)
- Status (open/closed)
Event card structure
- Event name
- Status pill (open / closed)
- Default flag
- Date
- Location
- Organiser
- Game system
- Scoring system
Event actions
| Action | Destination |
|---|---|
| Edit event | event_edit.html?id=X |
| Manage entrants | event_entrants.html?tournament_id=X |
These are the two primary workflow entry points. [oai_citation:2‡events.js](sediment://file_0000000057947243aeb1e7a6ff6d0f3f)
UX flow
- Page loads → auth check
- Header/footer fragments load
- Events loaded from API
- User filters/searches
- User selects action:
- Edit
- Manage entrants
Data model (client)
{
allItems: Event[]
}
Status handling
- Open → active events
- Closed → completed/inactive
Authentication
- Requires logged-in user
- 401 triggers logout redirect
Error handling
- Handles JSON + non-JSON responses
- Displays HTTP status + raw text when needed
HTTP 500 - raw response
Dependencies
TO/_api.jsapp_config.js- Header/footer fragments
Risks / observations
- No pagination
- Client-side filtering only
- Large datasets could degrade performance
Recommended improvements
- Add pagination
- Move filtering server-side
- Add sort options
- Add event duplication feature
Architecture classification
This is a Navigation Hub:
- Top-level TO entry
- Routes to deeper workflows
- Read-heavy UI