Example #1
0
 public OrderItem(Watch watch, int quanity)
 {
     Watch      = watch;
     Quanity    = quanity;
     TotalPrice = watch.Price * quanity;
 }
Example #2
0
 public void AddOrderItem(Watch watch, int quantity)
 {
     this.OrderItems.Add(new OrderItem(watch, quantity));
     this.totalPrice += this.OrderItems.Last().TotalPrice;
 }