public ActionResult Edit([Bind(Include = "LugarViajeId,Descripcion,TipoLugar")] LugarViaje lugarViaje) { if (ModelState.IsValid) { db.Entry(lugarViaje).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(lugarViaje)); }
public ActionResult Edit([Bind(Include = "BusId,Placa")] Bus bus) { if (ModelState.IsValid) { db.Entry(bus).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(bus)); }
public ActionResult Edit([Bind(Include = "ClienteId,Dni,Nombres,Apellidos")] Cliente cliente) { if (ModelState.IsValid) { db.Entry(cliente).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(cliente)); }
public ActionResult Edit([Bind(Include = "EmpleadoId,Dni,Nombres,Apellidos,Area,Cargo")] Administrativo administrativo) { if (ModelState.IsValid) { db.Entry(administrativo).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(administrativo)); }
public ActionResult Edit([Bind(Include = "EmpleadoId,Dni,Nombres,Apellidos,BusId,TipoTripulacion")] Tripulacion tripulacion) { if (ModelState.IsValid) { db.Entry(tripulacion).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.BusId = new SelectList(db.Buses, "BusId", "Placa", tripulacion.BusId); return(View(tripulacion)); }
public void StateModified(object Entity) { _Context.Entry(Entity).State = System.Data.Entity.EntityState.Modified; }