Add match counter
This commit is contained in:
@@ -156,11 +156,12 @@ public class TournamentController {
|
||||
return ResponseEntity.ok(tournamentMapper.toDto(tournamentPlayService.newRound(tournament, groupId)));
|
||||
}
|
||||
|
||||
@PostMapping("/tournaments/{tournamentId}/matches/{matchId}/start/{court}")
|
||||
public ResponseEntity<TournamentDto> startMatch(@PathVariable Long tournamentId, @PathVariable Long matchId, @PathVariable Long court) {
|
||||
@PostMapping("/tournaments/{tournamentId}/matches/{matchId}/start")
|
||||
public ResponseEntity<TournamentDto> startMatch(@PathVariable Long tournamentId, @PathVariable Long matchId,
|
||||
@RequestParam("court") Long court, @RequestParam("counter") Long counter) {
|
||||
var tournament = tournamentService.findTournamentById(tournamentId);
|
||||
|
||||
return ResponseEntity.ok(tournamentMapper.toDto(tournamentPlayService.startMatch(tournament, matchId, court)));
|
||||
return ResponseEntity.ok(tournamentMapper.toDto(tournamentPlayService.startMatch(tournament, matchId, court, counter)));
|
||||
}
|
||||
|
||||
@PostMapping("/tournaments/{tournamentId}/matches/{matchId}/stop")
|
||||
|
||||
Reference in New Issue
Block a user