public decimal PriceWithAdjustments() { var result = BasePrice; result += DiscountDetails.Sum(y => y.Amount); return(result); }
/// <summary> /// Total of all discounts /// </summary> /// <returns>Decimal</returns> public decimal TotalDiscounts() { if (DiscountDetails == null || DiscountDetails.Count < 1) { return(0); } return(IsFreeItem ? DiscountDetails.Where(s => s.DiscountType == PromotionType.OfferForFreeItems).Sum(y => y.Amount) : DiscountDetails.Sum(y => y.Amount)); }