public void EditFacultate(FacultateViewModel facultate) { Facultati oldFacultate = _facultatiServices.Get(facultate.Id); oldFacultate.Nume = facultate.Nume; _facultatiServices.Update(oldFacultate, oldFacultate.Id); }
public JsonResult AddFacultate(Facultati facultate) { try { Logic logic = new Logic(db); logic.AddFacultate(facultate); return(Json(Utils.JsonResponseFactory.SuccessResponse("Success"), JsonRequestBehavior.AllowGet)); } catch (Exception ex) { } return(Json(Utils.JsonResponseFactory.ErrorResponse("Error"), JsonRequestBehavior.AllowGet)); }
public void AddFacultate(Facultati facultate) { _facultatiServices.Add(facultate); }