Ejemplo n.º 1
0
        public ActionResult Edit(int id)
        {
            var adminRole = new AdminRole();

            var sandwichToUse = adminRole.GetSandwish(id);

            /*  var listIngredients = adminRole.GetIngredients().ToList<Ingredient>();
             * var listIngredientsIn = sandwichToUse.Ingredients.ToList<Ingredient>();
             * var listIngredientsOut = listIngredients.Except(listIngredientsIn);*/
            var listIngredientsOut = adminRole.GetMissingIngredients(sandwichToUse);

            return(View(new ViewModel_Sandwich_Ingredients(sandwichToUse, listIngredientsOut)));
        }