// GET: Maquina public ViewResult Index(int?pagina, string patrimonio) { int itensPorPagina = 12; int paginat = pagina ?? 1; List <MaquinaModel> lista = new List <MaquinaModel>(); lista = new MaquinaDao().Listar(new MaquinaModel { Patrimonio = patrimonio }); return(View(lista.ToPagedList(paginat, itensPorPagina))); }
// GET: Maquina/Delete/ public ActionResult Delete(int id) { var model = new MaquinaDao().Obter(id); return(View(model)); }