public CheckoutTransaction(ProductCatalog productCatalog, Promotions promotions)
 {
     this._productCatalog = productCatalog;
     _promotions = promotions;
     _items = new List<string>();
     this.Bill = new Bill(_items, _productCatalog, _promotions);
 }
예제 #2
0
 public Bill(IList<string> items, ProductCatalog productCatalog, Promotions promotions)
 {
     _items = items;
     _productCatalog = productCatalog;
     _promotions = promotions;
     CalculateBill();
 }
예제 #3
0
 public LineItem(string barcode, int quantity, ProductCatalog productCatalog, Promotions promotions)
 {
     _productCatalog = productCatalog;
     _promotions = promotions;
     Barcode = barcode;
     Quantity = quantity;
     DiscountNote = "";
     CalculatePriceAndSubTotal();
 }