Merges in parent ct names on each tab

This commit is contained in:
Per Ploug Krogslund
2015-07-06 15:19:15 +02:00
parent 0bf86e8286
commit 583c18bdd3

View File

@@ -130,8 +130,10 @@ namespace Umbraco.Web.Models.Mapping
//lock the tab
mainTab.Inherited = true;
//collect all the involved content types
mainTab.ParentTabContentTypes = groupOfGroups.Where(x => x.ContentTypeId != source.Id).Select(x => x.ContentTypeId);
//collect all the involved content types
var parents = groupOfGroups.Where(x => x.ContentTypeId != source.Id).ToList();
mainTab.ParentTabContentTypes = parents.Select(x => x.ContentTypeId);
mainTab.ParentTabContentTypeNames = parents.SelectMany(x => x.ParentTabContentTypeNames);
sortedGroups.Add(mainTab);
}
}