public ActionResult Edit([Bind(Include = "ID,otherthing1,otherthing2,otherthing3")] ParentTable parentTable) { if (ModelState.IsValid) { db.Entry(parentTable).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(parentTable)); }
public ActionResult Edit([Bind(Include = "ID,PID,thing1,thing2")] ChildTable childTable) { if (ModelState.IsValid) { db.Entry(childTable).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(childTable)); }