Class MatchController

java.lang.Object
com.futbol.manager.controller.GlobalCorsConfigController
com.futbol.manager.controller.MatchController

@RestController @RequestMapping("/rest/match") public class MatchController extends GlobalCorsConfigController
Controlador para los partidos
Author:
Alejandro
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    CreateFormPostPartido(com.futbol.manager.dto.RespPostPartidoDTO dto)
    metodo para crear un form de postpartido
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    CreateFormPrePartido(com.futbol.manager.dto.RespPrePartidoDTO dto)
    metodo para crear un form de prepartido
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    createUpdateGolPostPArtidoAvanzado(com.futbol.manager.dto.GolPostPartidoDTO dto, String postPartidoId)
    metodo para crear o actualizar un gol post partido avanzado
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    createUpdateInfoPlayerPostPartido(com.futbol.manager.dto.PlayerPostPartidoDTO player)
    metodo para crear o actualizar la info de los postpartidos
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    createUpdateMatchPreparation(com.futbol.manager.dto.MatchPreparationDTO match, String teamId)
    metodo para crear un entrenamiento
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    createUpdateMatchPreparation(com.futbol.manager.dto.PostPartidoDTO match)
    metodo para poder crear o editar un postpartido
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    deleteGolPostPArtidoAvanzado(String golPostPartidoId, String postPartidoId)
    metodo para eliminar un gol post partido avanzado
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    deletematchpreparation(com.futbol.manager.dto.MatchPreparationDTO match, String teamId)
    metodo para eliminar una preparacion de partido
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    GetFormPostPartidoByMatch(String matchPreparationId, String playerId)
    metodo para obtener los form de postpartido por id o pk
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    GetFormPrePartidoByMatch(String matchPreparationId, String playerId)
    metodo para obtener la info de un prepartido por id o pk
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    GetListFormPostMatch(String matchPreparationId)
    metodo para obtener la lista de postpartido
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    GetListFormPreMatch(String matchPreparationId)
    metodo para obtener la lista de prepartido
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    metodo para obtener la lista de goles a favor y en contra de un postpartido avanzado
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    metodo para obtener todos los partidos por teamID
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    aqui obtenemos el listado de tareas de un equipo y se van asignando al dia
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    metodo para obtener la lista de postpartido por equipo
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    getListPlayersByTeam(String teamId, String postPartidoId)
    metodo para obtener los jugadores de un postpartido
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    GetMatchPreparationById(String matchpreparationId)
    metodo para obtener los prepartidos por id o pk
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    metodo para obtener el postpartido y poder verlo pero por el matchPreparationId
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    metodo para obtener el postpartido pero por el postPartidoId
    org.springframework.http.ResponseEntity<com.futbol.manager.response.Response>
    PutVisibleMatch(String matchPreparationId, String visible)
    metodo para hacer visible o no un prepartido

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • MatchController

      public MatchController()
  • Method Details

    • GetListMatchPreparationByTeam

      @PreAuthorize("hasRole(\'ROLE_USER\')") @GetMapping("listmatchpreparationsbyteam/{teamId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> GetListMatchPreparationByTeam(@PathVariable String teamId)
      aqui obtenemos el listado de tareas de un equipo y se van asignando al dia
      Parameters:
      teamId -
      Returns:
    • GetMatchPreparationById

      @PreAuthorize("hasRole(\'ROLE_USER\')") @GetMapping("getmatchpreparationbyid/{matchpreparationId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> GetMatchPreparationById(@PathVariable String matchpreparationId)
      metodo para obtener los prepartidos por id o pk
      Parameters:
      matchpreparationId -
      Returns:
    • createUpdateMatchPreparation

      @PreAuthorize("hasRole(\'ROLE_USER\')") @PostMapping("createupdatematchpreparation/{teamId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> createUpdateMatchPreparation(@RequestBody com.futbol.manager.dto.MatchPreparationDTO match, @PathVariable String teamId)
      metodo para crear un entrenamiento
      Parameters:
      training -
      teamId -
      Returns:
    • deletematchpreparation

      @PreAuthorize("hasRole(\'ROLE_USER\')") @PostMapping("deletematchpreparation/{teamId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> deletematchpreparation(@RequestBody com.futbol.manager.dto.MatchPreparationDTO match, @PathVariable String teamId)
      metodo para eliminar una preparacion de partido
      Parameters:
      match -
      teamId -
      Returns:
    • getPostPartidoByMatchPreparationId

      @PreAuthorize("hasRole(\'ROLE_USER\')") @GetMapping("getpostpartidobymatchPreparationId/{matchPreparationId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> getPostPartidoByMatchPreparationId(@PathVariable String matchPreparationId)
      metodo para obtener el postpartido y poder verlo pero por el matchPreparationId
      Parameters:
      matchPreparationId -
      Returns:
    • getPostPartidoByPostPartidoId

      @PreAuthorize("hasRole(\'ROLE_USER\')") @GetMapping("getpostpartidobypostPartidoId/{postPartidoId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> getPostPartidoByPostPartidoId(@PathVariable String postPartidoId)
      metodo para obtener el postpartido pero por el postPartidoId
      Parameters:
      matchPreparationId -
      Returns:
    • createUpdateMatchPreparation

      @PreAuthorize("hasRole(\'ROLE_USER\')") @PostMapping("createupdatepostpartido") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> createUpdateMatchPreparation(@RequestBody com.futbol.manager.dto.PostPartidoDTO match)
      metodo para poder crear o editar un postpartido
      Parameters:
      match -
      Returns:
    • getListPlayersByTeam

      @PreAuthorize("hasRole(\'ROLE_USER\')") @GetMapping("getlistplayersbyteam/{teamId}/{postPartidoId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> getListPlayersByTeam(@PathVariable String teamId, @PathVariable String postPartidoId)
      metodo para obtener los jugadores de un postpartido
      Parameters:
      teamId -
      Returns:
    • createUpdateInfoPlayerPostPartido

      @PreAuthorize("hasRole(\'ROLE_USER\')") @PostMapping("createupdateinfoplayerpostpartido") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> createUpdateInfoPlayerPostPartido(@RequestBody com.futbol.manager.dto.PlayerPostPartidoDTO player)
      metodo para crear o actualizar la info de los postpartidos
      Parameters:
      player -
      Returns:
    • getListPlayersByTeam

      @PreAuthorize("hasRole(\'ROLE_USER\')") @GetMapping("getlistpostpartidobyteam/{teamId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> getListPlayersByTeam(@PathVariable String teamId)
      metodo para obtener la lista de postpartido por equipo
      Parameters:
      teamId -
      Returns:
    • PutVisibleMatch

      @PreAuthorize("hasRole(\'ROLE_USER\')") @GetMapping("updateMatchVisibility/{matchPreparationId}/{visible}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> PutVisibleMatch(@PathVariable String matchPreparationId, @PathVariable String visible)
      metodo para hacer visible o no un prepartido
      Parameters:
      matchPreparationId -
      visible -
      Returns:
    • CreateFormPrePartido

      @PreAuthorize("hasRole(\'ROLE_USER\')") @PostMapping("createformularioprepartido") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> CreateFormPrePartido(@RequestBody com.futbol.manager.dto.RespPrePartidoDTO dto)
      metodo para crear un form de prepartido
      Parameters:
      dto -
      Returns:
    • GetFormPrePartidoByMatch

      @PreAuthorize("hasRole(\'ROLE_USER\')") @GetMapping("getformprepartidobymatch/{matchPreparationId}/{playerId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> GetFormPrePartidoByMatch(@PathVariable String matchPreparationId, @PathVariable String playerId)
      metodo para obtener la info de un prepartido por id o pk
      Parameters:
      matchPreparationId -
      playerId -
      Returns:
    • CreateFormPostPartido

      @PreAuthorize("hasRole(\'ROLE_USER\')") @PostMapping("createformulariopostpartido") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> CreateFormPostPartido(@RequestBody com.futbol.manager.dto.RespPostPartidoDTO dto)
      metodo para crear un form de postpartido
      Parameters:
      dto -
      Returns:
    • GetFormPostPartidoByMatch

      @PreAuthorize("hasRole(\'ROLE_USER\')") @GetMapping("getformpostpartidobymatch/{matchPreparationId}/{playerId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> GetFormPostPartidoByMatch(@PathVariable String matchPreparationId, @PathVariable String playerId)
      metodo para obtener los form de postpartido por id o pk
      Parameters:
      matchPreparationId -
      playerId -
      Returns:
    • GetListFormPreMatch

      @PreAuthorize("hasRole(\'ROLE_USER\')") @GetMapping("getlistformprematch/{matchPreparationId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> GetListFormPreMatch(@PathVariable String matchPreparationId)
      metodo para obtener la lista de prepartido
      Parameters:
      matchPreparationId -
      Returns:
    • GetListFormPostMatch

      @PreAuthorize("hasRole(\'ROLE_USER\')") @GetMapping("getlistformpostmatch/{matchPreparationId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> GetListFormPostMatch(@PathVariable String matchPreparationId)
      metodo para obtener la lista de postpartido
      Parameters:
      matchPreparationId -
      Returns:
    • GetListGolesAvanzado

      @PreAuthorize("hasRole(\'ROLE_USER\')") @GetMapping("getlistgolesavanzado/{postPartidoId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> GetListGolesAvanzado(@PathVariable String postPartidoId)
      metodo para obtener la lista de goles a favor y en contra de un postpartido avanzado
      Parameters:
      postPartidoId -
      Returns:
    • GetListGolesAvanzadoByTeamId

      @PreAuthorize("hasRole(\'ROLE_USER\')") @GetMapping("getlistgolesavanzadobyteamid/{teamId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> GetListGolesAvanzadoByTeamId(@PathVariable String teamId)
      metodo para obtener todos los partidos por teamID
      Parameters:
      teamId -
      Returns:
    • createUpdateGolPostPArtidoAvanzado

      @PreAuthorize("hasRole(\'ROLE_USER\')") @PostMapping("createupdategolpostpartidoavanzado/{postPartidoId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> createUpdateGolPostPArtidoAvanzado(@RequestBody com.futbol.manager.dto.GolPostPartidoDTO dto, @PathVariable String postPartidoId)
      metodo para crear o actualizar un gol post partido avanzado
      Parameters:
      dto -
      postPartidoId -
      Returns:
    • deleteGolPostPArtidoAvanzado

      @PreAuthorize("hasRole(\'ROLE_USER\')") @GetMapping("deletegolpostpartidoavanzado/{golPostPartidoId}/{postPartidoId}") public org.springframework.http.ResponseEntity<com.futbol.manager.response.Response> deleteGolPostPArtidoAvanzado(@PathVariable String golPostPartidoId, @PathVariable String postPartidoId)
      metodo para eliminar un gol post partido avanzado
      Parameters:
      golPostPartidoId -
      Returns: