public ActionResult DeleteConfirmed(int id) { LideresV lideresV = db.LideresVs.Find(id); db.LideresVs.Remove(lideresV); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "ID,Nombre,Telefono,Email")] LideresV lideresV) { if (ModelState.IsValid) { db.Entry(lideresV).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(lideresV)); }
public ActionResult Create([Bind(Include = "ID,Nombre,Telefono,Email")] LideresV lideresV) { if (ModelState.IsValid) { db.LideresVs.Add(lideresV); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(lideresV)); }
// GET: LideresV/Delete/5 public ActionResult Delete(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } LideresV lideresV = db.LideresVs.Find(id); if (lideresV == null) { return(HttpNotFound()); } return(View(lideresV)); }