예제 #1
0
        public IActionResult GetAllLeagues()
        {
            var result = _leagueService.GetAllLeagues();

            if (result.ErrorOccurred)
            {
                return(BadRequest(result));
            }

            return(Ok(result));
        }
예제 #2
0
        public async Task <IActionResult> GetAll()
        {
            var view = await _leagueService.GetAllLeagues();

            return(Ok(view));
        }