public ActionResult DeleteConfirmed(int id) { TR_USER_COMPTE usercompte = db.TR_USER_COMPTE.Find(id); db.TR_USER_COMPTE.Remove(usercompte); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult UpdateUserCompte(TR_USER_COMPTE usercompte) { if (ModelState.IsValid) { db.Entry(usercompte).State = EntityState.Modified; db.SaveChanges(); return(Json("true")); } return(Json("false")); }
public ActionResult AddUserCompte(TR_USER_COMPTE usercompte) { if (ModelState.IsValid) { db.TR_USER_COMPTE.Add(usercompte); db.SaveChanges(); return(Json("true")); } return(Json("false")); }
public ActionResult Delete(int id = 0) { TR_USER_COMPTE usercompte = db.TR_USER_COMPTE.Find(id); if (usercompte == null) { return(HttpNotFound()); } return(View(usercompte)); }