예제 #1
0
        public async Task <IHttpActionResult> GetHop(int id)
        {
            var hopDto = await _hopService.GetSingleAsync(id);

            if (hopDto == null)
            {
                return(NotFound());
            }
            var result = new HopCompleteDto()
            {
                Hops = new List <HopDto>()
            };

            result.Hops.Add(hopDto);
            return(Ok(result));
        }