Esempio n. 1
0
        public static void CaseStudy1()
        {
            Custmore customer = new Custmore(101, "Abc", "Mumbai");
            LineItem laptop   = new LineItem(10001, 2, new Product(20002, "Hp", 450000));
            LineItem mobile   = new LineItem(10002, 3, new Product(3000, "1+", 45000));

            Order order1 = new Order(123, new DateTime(2019, 01, 05));

            order1.AddItem(laptop);
            order1.AddItem(mobile);

            customer.AddOrder(order1);

            InvoiceGenerator invoice = new InvoiceGenerator(customer);
        }
Esempio n. 2
0
 public InvoiceGenerator(Custmore customer)
 {
     _customer  = customer;
     _orderlist = _customer.OrderList;
     DisplayCustomerAndOrderDetais(_orderlist);
 }