// GET: Orcamento/Details/5 public ActionResult Details(int id) { var orcamento = _gerenciadorDeOrcamento.BuscarPorId(id); var orcamentoViewModel = Mapeador.Mapear <Orcamento, OrcamentoViewModel>(orcamento); return(View(orcamentoViewModel)); }
// GET: Details public HttpResponseMessage Get(int id) { HttpResponseMessage response; try { var orcamento = _gerenciadorDeOrcamento.BuscarPorId(id); response = Request.CreateResponse(HttpStatusCode.OK, orcamento); } catch (Exception ex) { response = Request.CreateErrorResponse(HttpStatusCode.InternalServerError, ex); } return(response); }