public ActionResult Edit([Bind(Include = "MId,Mname,Price")] Movie movie) { if (ModelState.IsValid) { db.Entry(movie).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(movie)); }
public ActionResult Edit([Bind(Include = "TId,Tname,Tlocation,MovieMId")] Theatre theatre) { if (ModelState.IsValid) { db.Entry(theatre).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.MovieMId = new SelectList(db.Movies, "MId", "Mname", theatre.MovieMId); return(View(theatre)); }