diff --git a/Sources/apiLOL/Controllers/ControllerChampions.cs b/Sources/apiLOL/Controllers/ControllerChampions.cs index 5911c45..7bc619f 100644 --- a/Sources/apiLOL/Controllers/ControllerChampions.cs +++ b/Sources/apiLOL/Controllers/ControllerChampions.cs @@ -24,8 +24,9 @@ namespace apiLOL.Controllers // GET: api/ [HttpGet] - public async Task Get() + public async Task Get([FromQuery] string name = "") { + //FromQuery permet de filtrer dans la collection de champions en fonction du nom _logger.LogInformation($"methode Get de ControllerChampions appelée"); _logger.LogInformation($"Nombre de champions : {await data.ChampionsMgr.GetNbItems()}"); var champs = (await data.ChampionsMgr.GetItems(0, await data.ChampionsMgr.GetNbItems())).Select(Model => Model.ToDTO());