public ShoppingBasketItem(ShoppingBasketItemInsertVM item) { Quantity = item.Quantity; Price = item.Price; ProductName = item.ProductName; ProductId = item.ProductId; }
public void AddItemToBasket(int customerId, [FromBody] ShoppingBasketItemInsertVM newItem) { var item = new ShoppingBasketItem(newItem); _shoppingBasketService.AddItemToBasket(customerId, item); }