Exemple #1
0
        public static void Start()
        {
            while (true)
            {
                Console.Clear();
                Console.WriteLine("*********************************************");
                Console.WriteLine();
                Console.WriteLine("1. Display Orders");
                Console.WriteLine("2. Add an Order");
                Console.WriteLine("3. Edit an Order");
                Console.WriteLine("4. Remove an Order");
                Console.WriteLine("5. Quit");
                Console.WriteLine();
                Console.Write("Enter selection: ");
                string userinput = Console.ReadLine();

                switch (userinput)
                {
                case "1":
                    OrderLookupWorkflow lookupWorkflow = new OrderLookupWorkflow();
                    lookupWorkflow.Execute();
                    break;

                case "2":
                    AddNewOrderWorkflow AddOrderWorkflow = new AddNewOrderWorkflow();
                    AddOrderWorkflow.Execute();
                    break;

                case "3":
                    EditOrderWorkflow EditOrder = new EditOrderWorkflow();
                    EditOrder.Execute();
                    break;

                case "4":
                    RemoveOrderWorkflow RemoveOrder = new RemoveOrderWorkflow();
                    RemoveOrder.Execute();
                    break;

                case "5":
                    return;
                }
            }
        }
Exemple #2
0
        public static void Start()
        {
            Console.Clear();
            Console.WriteLine("****************************");
            Console.WriteLine("* Flooring Mastery Project *");
            Console.WriteLine("****************************");
            Console.WriteLine();
            Console.WriteLine("1. Display Order: ");
            Console.WriteLine("2. Add New Order: ");
            Console.WriteLine("3. Edit Order: ");
            Console.WriteLine("4. Remove Order: ");
            Console.WriteLine("\nQ to quit: ");
            Console.WriteLine("\nPlease enter selection: ");

            string userinput = Console.ReadLine();

            switch (userinput)
            {
            case "1":
                DisplayOrderWorkflow displayWorkflow = new DisplayOrderWorkflow();
                displayWorkflow.Execute();
                break;

            case "2":
                AddNewOrderWorkflow addWorkflow = new AddNewOrderWorkflow();
                addWorkflow.Execute();
                break;

            case "3":
                EditOrderWorkflow editWorkflow = new EditOrderWorkflow();
                editWorkflow.Execute();
                break;

            case "4":
                RemoveOrderWorkflow removeWorkflow = new RemoveOrderWorkflow();
                removeWorkflow.Execute();
                break;

            case "Q":
                return;
            }
        }