示例#1
0
        public ActionResult Aprobar(int?id)
        {
            try
            {
                Planner_mantenimiento planner_mantenimiento = db.Planner_mantenimiento.Where(f => f.CodPlanner == id).FirstOrDefault();
                planner_mantenimiento.CodEstado       = 3;
                db.Entry(planner_mantenimiento).State = EntityState.Modified;
                db.SaveChanges();
            }
            catch (Exception ex) {
                utils.EventLogger.EscribirLog(ex.ToString());
            }

            return(RedirectToAction("Index"));
        }
 public ActionResult Edit([Bind(Include = "CodPlanner,CodPeriodo,CodInstalacion,FechaProg,codestado")] Programacion programacion)
 {
     if (ModelState.IsValid)
     {
         db.Entry(programacion).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(programacion));
 }
示例#3
0
 public ActionResult Edit([Bind(Include = "CodConsolidado,FechaRegistro,CodPlanner,CodPeriodo,CodEstado")] Calidad_Mantenimiento calidad_Mantenimiento)
 {
     if (ModelState.IsValid)
     {
         db.Entry(calidad_Mantenimiento).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(calidad_Mantenimiento));
 }
示例#4
0
 public ActionResult Edit([Bind(Include = "CodArticulo,NomArticulo,UnidMedida,Modelo,Observacion")] Articulo articulo)
 {
     if (ModelState.IsValid)
     {
         db.Entry(articulo).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(articulo));
 }
示例#5
0
 public ActionResult Edit([Bind(Include = "CodPeriodo,NomPeriodo,NomActividad,FechaInicio,FechaFin")] Periodo_Academico periodo_Academico)
 {
     if (ModelState.IsValid)
     {
         db.Entry(periodo_Academico).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(periodo_Academico));
 }
示例#6
0
 public ActionResult Edit([Bind(Include = "CodInstalacion,NomInstalacion,AbrevInstalacion,Aforo")] Instalacion instalacion)
 {
     if (ModelState.IsValid)
     {
         db.Entry(instalacion).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(instalacion));
 }
示例#7
0
 public ActionResult Edit([Bind(Include = "CodTarea,NomTarea,AbrevTarea")] Tarea tarea)
 {
     if (ModelState.IsValid)
     {
         if (exists(tarea) == false)
         {
             db.Entry(tarea).State = EntityState.Modified;
             db.SaveChanges();
         }
         return(RedirectToAction("Index"));
     }
     return(View(tarea));
 }