public Order UpdateOrder(Order order) { var entry = _db.Entry(order); entry.State = EntityState.Modified; return(order); }
public Product UpdateProduct(Product product) { var entry = _db.Entry(product); entry.State = EntityState.Modified; return(product); }
public virtual async Task <bool> Update(T entity) { _db.Entry(entity).State = EntityState.Modified; return(await _db.SaveChangesAsync() > 0); }
public Cart Update(Cart cart) { _db.Carts.Attach(cart); _db.Entry(cart).State = EntityState.Modified; return(cart); }