Reputation: 1848
In EpiServer 11, I want to enforce what blocks get can added to which folders under blocks. Following this article:
This works, but the folders can only be one level deep. That is I cant add any custom folders that reside inside other custom folders. Is there a way to control this?
Upvotes: 0
Views: 314
Reputation: 1848
This was due to a lack of understanding about configuration. This was my folder:
[ContentType(DisplayName = "Settings Folder", GUID = "1422f7b1-a6aa-485f-a7f3-4049c9343f06", Description = "")]
[AvailableContentTypes(Availability.Specific, Include = new [] { typeof(SiteSettingsBlock), typeof(HeaderSettingsBlock), typeof(FooterSettingsBlock)})]
public class SettingsFolder : ContentFolder
{
}
All I needed to do was add Content Folder as an available type:
[ContentType(DisplayName = "Settings Folder", GUID = "1422f7b1-a6aa-485f-a7f3-4049c9343f06", Description = "")]
[AvailableContentTypes(Availability.Specific, Include = new [] { typeof(SiteSettingsBlock), typeof(HeaderSettingsBlock), typeof(FooterSettingsBlock), typeof(ContentFolder)})]
public class SettingsFolder : ContentFolder
{
}
Upvotes: 2