Konstrukt
Search…
Child Collections
Configuring child collections in Konstrukt, the back office UI builder for Umbraco.
A child collection is a container for a given data model that is tied to a parent collection data model. It shares all of the Collections config builder API except child collections cannot contain further child collections.
Child Collections
Child Collections UI: By default, child collections will be presented in the UI as context apps in the parent models editor view. If you have multiple child collections that make the context apps area over populated, you can use the Child Collection Groups API to group child collections under a single context app with the inner child collections then being presented in tabs.

You define a child collection by calling one of the AddChildCollection methods on a given collection config builder instance.

Adds a child collection to the current collection with the given names and description and default icons. A property accessor expression is required for both the entity ID field and FK (Foreign Key) field of the entity.
// Example
collectionConfig.AddChildCollection<Child>(c => c.Id, c => c.ParentId, "Child", "Children", "A collection of children", childCollectionConfig => {
...
});

Adds a child collection to the current collection with the given names, description and icons. A property accessor expression is required for both the entity ID field and FK (Foreign Key) field of the entity.
// Example
collectionConfig.AddChildCollection<Child>(c => c.Id, c => c.ParentId, "Child", "Children", "A collection of children", "icon-umb-users", "icon-umb-users", childCollectionConfig => {
...
});

Child collections share the same API as the Collection config builder API, except child collections cannot contain further child collections. Please see the core collections documentation for more info.
Copy link
Edit on GitHub
On this page
Defining a child collection
Configuring a child collection