public IEnumerable <Food.Models.Food> GetFoods() { var foodRepo = new FoodRepo(); var foods = foodRepo.GetFoods(); return(foods); }
public IEnumerable <FoodModel> GetSecondaryFoods() { var foodRepo = new FoodRepo(); var foods = foodRepo.GetFoods().Where(f => f.Type == 2) .Select(f => new FoodModel() { Id = f.Id, Name = f.Name, Type = f.Type }) .OrderBy(f => f.Name); return(foods); }