public ActionResult DeleteConfirmed(int id) { ReguladoPor reguladoPor = db.ReguladoPor.Find(id); db.ReguladoPor.Remove(reguladoPor); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "IdReguladoPor,IdPresentado,NroMarcoRegulatorio")] ReguladoPor reguladoPor) { if (ModelState.IsValid) { db.Entry(reguladoPor).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.NroMarcoRegulatorio = new SelectList(db.MarcoRegulatorio, "Nro", "Duracion", reguladoPor.NroMarcoRegulatorio); ViewBag.IdPresentado = new SelectList(db.Presentado, "IdPresentado", "IdPresentado", reguladoPor.IdPresentado); return(View(reguladoPor)); }
// GET: ReguladoPor/Details/5 public ActionResult Details(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } ReguladoPor reguladoPor = db.ReguladoPor.Find(id); if (reguladoPor == null) { return(HttpNotFound()); } return(View(reguladoPor)); }
// GET: ReguladoPor/Edit/5 public ActionResult Edit(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } ReguladoPor reguladoPor = db.ReguladoPor.Find(id); if (reguladoPor == null) { return(HttpNotFound()); } ViewBag.NroMarcoRegulatorio = new SelectList(db.MarcoRegulatorio, "Nro", "Duracion", reguladoPor.NroMarcoRegulatorio); ViewBag.IdPresentado = new SelectList(db.Presentado, "IdPresentado", "IdPresentado", reguladoPor.IdPresentado); return(View(reguladoPor)); }