Conversation
Module 1.4.7 REST API Module 1.2.4 API Design (3 endpoints)
There was a problem hiding this comment.
Pull request overview
Adds tournament creation plus schedule generation and retrieval endpoints to the backend, including new persistence tables for tournaments/teams/venues/matches.
Changes:
- Introduces tournament service/model/controller layers for creating tournaments and generating/getting schedules.
- Adds
/api/tournamentscreation and schedule generate/fetch endpoints via a new router. - Extends the database schema with tournaments, teams, venues, and matches tables.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 8 comments.
Show a summary per file
| File | Description |
|---|---|
| backend/src/services/tournamentService.ts | Validates tournament creation payload and generates round-robin schedules, then persists matches. |
| backend/src/controllers/tournamentController.ts | Adds REST handlers for tournament creation and schedule generate/fetch endpoints. |
| backend/src/routes/tournamentRoute.ts | Defines tournament-related routes. |
| backend/src/models/tournamentModel.ts | Adds DB queries/transactions for tournament creation and schedule storage/retrieval. |
| backend/src/index.ts | Registers the new tournament router under /api. |
| backend/src/database/BracketBeaverDB.sql | Adds schema for tournaments/teams/venues/matches. |
| backend/.env.example | Updates example DATABASE_URL value. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
|
@copilot open a new pull request to apply changes based on the comments in this thread |
|
@rapidcoderx I've opened a new pull request, #3, to work on those changes. Once the pull request is ready, I'll request review from you. |
[WIP] Add schedule generation features to the API
carson-fn
left a comment
There was a problem hiding this comment.
Add the frontend to this branch so we can test that everything works then we can merge it.
Also I don't think copilot made the changes because the old stuff is still there. Try clicking commit suggestion maybe?
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
|
Added the frontend. We can view basic bracket generation currently and fulfill the main functionalities. |
There was a problem hiding this comment.
Pull request overview
Adds end-to-end tournament schedule generation (single-elimination + round-robin), exposes it via new REST endpoints, and introduces a frontend page to create tournaments, generate brackets, and submit match results.
Changes:
- Implement tournament creation, schedule generation, bracket retrieval, and match-result updates in the backend (service/model/controller/route).
- Add a new tournaments UI page (create/generate/load bracket, submit scores, quick-advance winners) plus styling.
- Add startup-time DB schema adjustment logic and extend the SQL schema with tournament-related tables.
Reviewed changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 8 comments.
Show a summary per file
| File | Description |
|---|---|
| frontend/src/pages/tournaments/styles/tournamentStyles.css | New styles for the tournaments page and bracket UI. |
| frontend/src/pages/tournaments/TournamentPage.tsx | New tournaments page to create/generate/load brackets and update results. |
| frontend/src/pages/login/LoginPage.tsx | Stores logged-in user in localStorage and navigates to tournaments page. |
| frontend/src/api/tournamentApi.ts | New API wrapper for tournament endpoints (create/generate/bracket/result). |
| frontend/src/App.tsx | Adds /tournaments route. |
| backend/src/services/tournamentService.ts | Core tournament validation, schedule generation, bracket shaping, and result propagation. |
| backend/src/routes/tournamentRoute.ts | Defines tournament REST endpoints. |
| backend/src/models/tournamentModel.ts | DB access layer for tournaments/teams/venues/matches. |
| backend/src/index.ts | Registers tournament routes and runs DB schema setup before listening. |
| backend/src/database/database.ts | Adds ensureDatabaseSchema() startup migration logic. |
| backend/src/database/BracketBeaverDB.sql | Adds tournaments/teams/venues/matches tables and indexes. |
| backend/src/controllers/tournamentController.ts | Request validation + HTTP handlers for tournament endpoints. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
@rapidcoderx I've opened a new pull request, #7, to work on those changes. Once the pull request is ready, I'll request review from you. |
|
@rapidcoderx I've opened a new pull request, #8, to work on those changes. Once the pull request is ready, I'll request review from you. |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
[WIP] [WIP] Addressing feedback on schedule gen features PR
[WIP] [WIP] Address changes based on feedback for Schedule Gen features PR
carson-fn
left a comment
There was a problem hiding this comment.
Looks good, just need to resolve merge conflicts.
- restored llm integration files
Completed three tasks:
1.4.4 Schedule Generation Module
1.4.7 REST API Module
1.2.4 API Design (3 endpoints)