예제 #1
0
        public async Task <IActionResult> GetAsync(int id)
        {
            if (!ModelState.IsValid)
            {
                return(new BadRequestObjectResult(ModelState));
            }

            var result = await _service.GetList(id).ConfigureAwait(false);

            if (result == null)
            {
                return(new NotFoundResult());
            }

            return(new ObjectResult(result.ToCoordinateListDto()));
        }