public ActionResult Create(Etudiant Etudiant) { if (ModelState.IsValid) { try { etudiantsRepo.Add(Etudiant); return(RedirectToAction(nameof(Index))); } catch { return(View()); } } else { ModelState.AddModelError("", "you have problem"); return(View()); } }
public bool Add(E_Model.School model) { return(dal.Add(model)); }