public ActionResult DeleteConfirmed(decimal id) { CALENDARIO cALENDARIO = db.CALENDARIO.Find(id); db.CALENDARIO.Remove(cALENDARIO); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "ID_FERIADO,ID_PAIS,FECHA_NO_LABORAL,DESCRIPCION_NO_LABORAL")] CALENDARIO cALENDARIO) { if (ModelState.IsValid) { db.Entry(cALENDARIO).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.ID_PAIS = new SelectList(db.PAISES, "ID_PAIS", "NOM_PAIS", cALENDARIO.ID_PAIS); return(View(cALENDARIO)); }
// GET: CALENDARIOs/Details/5 public ActionResult Details(decimal id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } CALENDARIO cALENDARIO = db.CALENDARIO.Find(id); if (cALENDARIO == null) { return(HttpNotFound()); } return(View(cALENDARIO)); }
// GET: CALENDARIOs/Edit/5 public ActionResult Edit(decimal id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } CALENDARIO cALENDARIO = db.CALENDARIO.Find(id); if (cALENDARIO == null) { return(HttpNotFound()); } ViewBag.ID_PAIS = new SelectList(db.PAISES, "ID_PAIS", "NOM_PAIS", cALENDARIO.ID_PAIS); return(View(cALENDARIO)); }