public static OrderLineItem FromShoppingCartItem(ICartItem cartItem) { // Creates a new one ( ready for the db ) return new OrderLineItem { ProductId = cartItem.Id, Quantity = cartItem.Quantity, TaxTotal = cartItem.CalculateTotalTax(), TotalValue = cartItem.CalculateSubTotalWithoutTax(), UnitPrice = cartItem.PriceWithoutTax, CreatedDateTime = DateTime.Now, ProductName = cartItem.Title }; }