public IHttpActionResult deleteCart(Cart cart) { var delCart = Uow.Repository <Cart>().FindBy(c => c.UserId == cart.UserId).ToList(); delCart.ForEach(t => { CartDomain.Delete(t); }); return(Ok()); }
public IHttpActionResult Delete(Cart item) { var delCartItem = Uow.Repository <Cart>().FirstOrDefault(c => c.CartId == item.CartId); return(Ok(CartDomain.Delete(delCartItem))); }