upcoming tournament page, minor changes
This commit is contained in:
@@ -18,6 +18,17 @@ export function createTournamentsService(pb: PocketBase) {
|
||||
});
|
||||
return transformTournament(result);
|
||||
},
|
||||
async getMostRecentTournament(): Promise<Tournament> {
|
||||
const result = await pb
|
||||
.collection("tournaments")
|
||||
.getFirstListItem('',
|
||||
{
|
||||
expand: "teams, teams.players, matches, matches.tournament, matches.home, matches.away",
|
||||
sort: "-created",
|
||||
}
|
||||
);
|
||||
return transformTournament(result);
|
||||
},
|
||||
async listTournaments(): Promise<TournamentInfo[]> {
|
||||
const result = await pb
|
||||
.collection("tournaments")
|
||||
|
||||
Reference in New Issue
Block a user