Ejemplo n.º 1
0
        public void SetOptions()
        {
            MenuOptions.Add("1. Cancel");
            MenuOptions.Add("2. Preview Order");
            MenuOptions.Add("3. Build Your Own");
            var i         = 3;
            var pizzaList = DataAccessor.GetPresetPizzas();

            foreach (var pizzaID in pizzaList)
            {
                i++;
                APizza newPizza = Factory.CreateAPizza();
                newPizza.BuildPizzaFromData(DataAccessor.CreatePresetPizza(pizzaID));
                PizzaList.Add(newPizza);
                MenuOptions.Add($"{i}. {newPizza.Name}");
            }
        }