public ActionResult Edit_Mission([Bind(Include = "MID,CID,MName,MDetail")] Mission mission) { if (ModelState.IsValid) { db.Entry(mission).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index_Mission")); } return(View(mission)); }
public ActionResult Edit_Admin([Bind(Include = "AID,APassword,AName")] Admin admin) { if (ModelState.IsValid) { db.Entry(admin).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(admin)); }
public ActionResult Edit([Bind(Include = "TEID,MID,GID,TeacherA,GroupAchievementLevel")] TeacherAssessment teacherAssessment) { if (ModelState.IsValid) { db.Entry(teacherAssessment).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(teacherAssessment)); }
public ActionResult Edit_Course([Bind(Include = "CID,TID,CName")] Course course) { if (ModelState.IsValid) { db.Entry(course).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index_Course")); } ViewBag.TID = new SelectList(db.Teachers, "TID", "TName", course.TID); return(View(course)); }