public void Update(ALevelRport lvl) { db.Entry(lvl).State = EntityState.Modified; db.Configuration.ValidateOnSaveEnabled = false; Save(); db.Configuration.ValidateOnSaveEnabled = true; }
public ActionResult Create(ALevelRport report) { try { objBs.Insert(report); TempData["Msg"] = "Report added succesfuly"; return RedirectToAction("Index"); } catch (Exception e) { TempData["Msg"] = "Failed to add the report " + e.Message; return RedirectToAction("Index"); } }
public void Update(ALevelRport lvl) { objDb.Update(lvl); }
public void Insert(ALevelRport lvl) { objDb.Insert(lvl); }
public void Insert(ALevelRport lvl) { db.ALevelRports.Add(lvl); Save(); }