Ejemplo n.º 1
0
 public ActionResult Creat(SliderHome_Lang sliderItem)
 {
     if (ModelState.IsValid)
     {
         dbContext.SliderHomes_Lang.Add(sliderItem);
         dbContext.SaveChanges();
         return null;
     }
     return new HttpStatusCodeResult(400, "lỗi tạo menu ngôn ngữ");
 }
Ejemplo n.º 2
0
 public ActionResult Update(SliderHome_Lang sliderItem)
 {
     if (ModelState.IsValid)
     {
         dbContext.Entry(sliderItem).State = EntityState.Modified;
         dbContext.SaveChanges();
         return null;
     }
     else
     {
         return new HttpStatusCodeResult(400, "lỗi update menu ngôn ngữ");
     }
 }