public ActionResult DeleteConfirmed(int id) { StudentParticularType studentparticulartype = db.StudentParticularTypes.Find(id); db.StudentParticularTypes.Remove(studentparticulartype); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit(StudentParticularType studentparticulartype) { if (ModelState.IsValid) { db.Entry(studentparticulartype).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(studentparticulartype)); }
public ActionResult Edit(int id = 0) { StudentParticularType studentparticulartype = db.StudentParticularTypes.Find(id); if (studentparticulartype == null) { return(HttpNotFound()); } return(View(studentparticulartype)); }
public ActionResult Create(StudentParticularType studentparticulartype) { if (ModelState.IsValid) { db.StudentParticularTypes.Add(studentparticulartype); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(studentparticulartype)); }