feat: add error handling to player creation and update gitignore for agent

This commit is contained in:
Erik Silva
2026-01-24 14:18:40 -03:00
commit 416bd83ea7
93 changed files with 16861 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
-- AlterTable
ALTER TABLE "Match" ADD COLUMN "drawSeed" TEXT,
ADD COLUMN "location" TEXT,
ADD COLUMN "maxPlayers" INTEGER;
-- CreateTable
CREATE TABLE "Attendance" (
"id" TEXT NOT NULL,
"playerId" TEXT NOT NULL,
"matchId" TEXT NOT NULL,
"status" TEXT NOT NULL DEFAULT 'CONFIRMED',
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
CONSTRAINT "Attendance_pkey" PRIMARY KEY ("id")
);
-- CreateIndex
CREATE UNIQUE INDEX "Attendance_playerId_matchId_key" ON "Attendance"("playerId", "matchId");
-- AddForeignKey
ALTER TABLE "Attendance" ADD CONSTRAINT "Attendance_playerId_fkey" FOREIGN KEY ("playerId") REFERENCES "Player"("id") ON DELETE RESTRICT ON UPDATE CASCADE;
-- AddForeignKey
ALTER TABLE "Attendance" ADD CONSTRAINT "Attendance_matchId_fkey" FOREIGN KEY ("matchId") REFERENCES "Match"("id") ON DELETE RESTRICT ON UPDATE CASCADE;