public IEnumerable GetCountFoodInTypes() { return(Foods?.GroupBy(f => f.Type.Name) .Select(t => new { Type = t.Key, CountFoods = t.Count() }).ToList()); }