public IActionResult Add(productos model) { if (model.id.HasValue) { model = new productos().GetAllById(model.id.Value).JsonToObj <List <productos> >().FirstOrDefault(); } return(VariablesGlobales.View(View(model), "Administrator")); }
public IActionResult Detalle(productos model) { if (!model.id.HasValue) { return(Redirect("/Productos")); } model = model.GetAllById(model.id.Value).JsonToObj <List <productos> >().FirstOrDefault(); return(VariablesGlobales.View(View(model), "Administrator")); }
public IActionResult Index() { return(VariablesGlobales.View(View(VariablesGlobales.LogUser), "Administrator")); }
public IActionResult Index() { List <productos> productos = JsonConvert.DeserializeObject <List <productos> >(new productos().GetAll()); return(VariablesGlobales.View(View(productos))); }