Example #1
0
 public void UpdateProduct(Product product)
 {
     db.Products.AddOrUpdate(product);
     db.SaveChanges();
 }
Example #2
0
 public long Insert(User entity)
 {
     db.Users.Add(entity);
     db.SaveChanges();
     return(entity.ID);
 }
Example #3
0
 public void UpdateProductCategory(ProductCategory productCategory)
 {
     db.ProductCategories.AddOrUpdate(productCategory);
     db.SaveChanges();
 }
Example #4
0
 public long Insert(Feedback entity)
 {
     db.Feedbacks.Add(entity);
     db.SaveChanges();
     return(entity.ID);
 }
 public void Commit()
 {
     _context.SaveChanges();
 }