public void Load() { ContentItems.ClearAndLoad(_sessionRepository.LoadContentItems().OrderBy(x => x.Name)); ContentItemsByTypeGroups.Clear(); foreach (var type in ContentItems.GroupBy(x => x.ContentType.Content).OrderBy(x => x.Key)) { var contentItemsByTypeGroup = new ContentItemsByTypeGroup(type.Key, type.OrderBy(x => x.Name)); ContentItemsByTypeGroups.Add(contentItemsByTypeGroup); } }