The junction table was a redundant second source of truth: syncTournamentResults already fans out by querying scoring_events.tournamentId directly, so the table only served the admin UI and could drift out of sync (causing orphaned events). - Drop sports_season_tournaments table and all link/unlink admin actions - Add getTournamentsBySportsSeason / getSportsSeasonsByTournament helpers that derive the same information from scoring_events.tournamentId - Add "Add Existing Tournament" dropdown to the events admin page (qualifying_points seasons only) — selecting a tournament creates the scoring event in one step - Fix clone: scoring events now carry tournamentId, fixing a latent check-constraint violation when cloning qualifying_points seasons - Tournament admin page "Linked Sports Seasons" is now a read-only derived view Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
25 lines
808 B
TypeScript
25 lines
808 B
TypeScript
// Re-export all model functions and types
|
|
export * from "./user";
|
|
export * from "./league";
|
|
export * from "./season";
|
|
export * from "./team";
|
|
export * from "./commissioner";
|
|
export * from "./sport";
|
|
export * from "./sports-season";
|
|
export * from "./season-participant";
|
|
export * from "./season-template";
|
|
export * from "./season-template-sport";
|
|
export * from "./season-sport";
|
|
export * from "./participant-result";
|
|
export * from "./draft-slot";
|
|
export * from "./draft-pick";
|
|
export * from "./draft-queue";
|
|
export * from "./draft-timer";
|
|
export * from "./draft-utils";
|
|
export * from "./watchlist";
|
|
export * from "./audit-log";
|
|
export * from "./tournament";
|
|
export * from "./participant";
|
|
export * from "./tournament-result";
|
|
export * from "./canonical-surface-elo";
|
|
export * from "./canonical-golf-skills";
|