static void Main(string[] args) { //Create a Warehouse object Ladu currentlyInStock = new Ladu(); ShoppingCart shoppingCart = new ShoppingCart(); Console.WriteLine("Siin menüü"); currentlyInStock.AinedPrintInStock(); currentlyInStock.TainadPrintInStock(); AddItemsToShoppingCart(currentlyInStock, shoppingCart); }
public static void AddItemsToShoppingCart(Ladu currentlyInStock, ShoppingCart shoppingCart) { Console.WriteLine("Sisesta nr 1-10 ingredients: "); int productID1 = int.Parse(Console.ReadLine()); Console.WriteLine("Enter the number of items to add to the shopping cart: "); int quantity = int.Parse(Console.ReadLine()); Console.WriteLine("Sisesta nr 11-12 taignad: "); int productID2 = int.Parse(Console.ReadLine()); /*Ingredients articleToAdd1 = currentlyInStock.GetFromStock1(productID1); * Taignad articleToAdd2 = currentlyInStock.GetFromStock2(productID2); * shoppingCart.AddToShoppingCart(articleToAdd1, quantity); * shoppingCart.PrintShoppingCart();*/ }