public ActionResult DeleteConfirmed(int id) { Registered_user registered_user = db.Registered_user.Find(id); db.Registered_user.Remove(registered_user); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit([Bind(Include = "User_id,Email_id,Password_user")] Registered_user registered_user) { if (ModelState.IsValid) { db.Entry(registered_user).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(registered_user)); }
public ActionResult Create([Bind(Include = "User_id,Email_id,Password_user")] Registered_user registered_user) { if (ModelState.IsValid) { db.Registered_user.Add(registered_user); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(registered_user)); }
// GET: Registered_user/Delete/5 public ActionResult Delete(int?id) { if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } Registered_user registered_user = db.Registered_user.Find(id); if (registered_user == null) { return(HttpNotFound()); } return(View(registered_user)); }