Skip to content

Commit 3ad2e74

Browse files
authored
Merge pull request #11145 from umbraco/v8/bugfix/11114-nested-content-not-rendering
Fixes Nested Content not rendering
2 parents 27e74e7 + 5796b84 commit 3ad2e74

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

src/Umbraco.Web.UI.Client/src/views/propertyeditors/nestedcontent/nestedcontent.controller.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -535,7 +535,7 @@
535535
// remove all tabs except the specified tab
536536
var tabs = scaffold.variants[0].tabs;
537537
var tab = _.find(tabs, function (tab) {
538-
return tab.id !== 0 && (tab.alias.toLowerCase() === contentType.ncTabAlias.toLowerCase() || contentType.ncTabAlias === "");
538+
return tab.id !== 0 && (tab.label.toLowerCase() === contentType.ncTabAlias.toLowerCase() || contentType.ncTabAlias === "");
539539
});
540540
scaffold.variants[0].tabs = [];
541541
if (tab) {

src/Umbraco.Web/PropertyEditors/NestedContentController.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
1-
using System.Collections.Generic;
1+
using System.Collections.Generic;
22
using System.Linq;
3+
using Umbraco.Core.Models;
34
using Umbraco.Core.Services;
45
using Umbraco.Web.Editors;
56
using Umbraco.Web.Mvc;
@@ -22,7 +23,7 @@ public IEnumerable<object> GetContentTypes()
2223
name = x.Name,
2324
alias = x.Alias,
2425
icon = x.Icon,
25-
tabs = x.CompositionPropertyGroups.Select(y => y.Name).Distinct()
26+
tabs = x.CompositionPropertyGroups.Where(x => x.Type == PropertyGroupType.Group && x.GetParentAlias() == null).Select(y => y.Name).Distinct()
2627
});
2728
}
2829
}

0 commit comments

Comments
 (0)