Beispiel #1
0
        public void RemoveMealByName()
        {
            Console.Clear();

            Console.WriteLine("Name the meal you would like to remove: \n");
            var mealName = Console.ReadLine();

            foreach (var cafeMenu in _menuRepo.GetList())
            {
                if (mealName == cafeMenu.Name)
                {
                    _menuRepo.RemoveMealByName(cafeMenu);
                    break;
                }
            }

            PrintAllMenuItemswithDetails();

            Console.WriteLine("Your Meal has been successfully removed!");

            Console.ReadLine();
        }