public ActionResult <IEnumerable <string> > GetAll() { try { return(Ok(_enderecoAppService.GetAll())); } catch (Exception ex) { throw ex; } }
// GET: Enderecos public ActionResult Index() { var enderecoViewModel = Mapper.Map <IEnumerable <Endereco>, IEnumerable <EnderecoViewModel> >(_enderecoApp.GetAll()); return(View(enderecoViewModel)); }
// GET: api/Endereco public IEnumerable <EnderecoViewModel> Get() { return(Mapper.Map <IEnumerable <Endereco>, IEnumerable <EnderecoViewModel> >(_enderecoApp.GetAll())); }
// GET: Endereco public ActionResult Index() { return(View(_app.GetAll())); }