settings link, uneroll team server fn

This commit is contained in:
yohlo
2025-08-24 00:35:38 -05:00
parent 53276cc18e
commit 324e1742f1
9 changed files with 112 additions and 14 deletions

View File

@@ -57,5 +57,16 @@ export function createTournamentsService(pb: PocketBase) {
);
return transformTournament(result);
},
async unenrollTeam(
tournamentId: string,
teamId: string
): Promise<Tournament> {
const result = await pb.collection("tournaments").update<Tournament>(
tournamentId,
{ "teams-": teamId },
{ expand: "teams, teams.players" }
);
return transformTournament(result);
},
};
}