예제 #1
0
        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");                
            }


        }
예제 #3
0
 public void Update(ALevelRport lvl)
 {
     objDb.Update(lvl);
 }
예제 #4
0
 public void Insert(ALevelRport lvl)
 {
     objDb.Insert(lvl);
 }
예제 #5
0
 public void Insert(ALevelRport lvl)
 {
     db.ALevelRports.Add(lvl);
     Save();
 }