示例#1
0
        public IActionResult BuscarPorId([FromRoute] int id)
        {
            try
            {
                var resultBD = _forecastService.BuscarPorId(id);

                var resultVM = Mapper.Map <ForecastVM>(resultBD);

                return(Ok(new { dados = resultVM, notifications = "", success = true }));
            }
            catch (Exception ex)
            {
                return(BadRequest(ex.Message));
            }
        }