I'm new to the latest ModelBuilders package that has been baked into Umbraco Core but am reviewing it to replace the Umbraco Mapper package that I currently use in a 3+ year old site.
I'm having issues finding how to render a composition property that needs to recursively populate up to the root if no value is set on the current page.
For context, this is a carosel banner, where child pages may or may not select images to show directly, but in which case should default to showing whatever banner images are configured on the root "Home" node.
I have a partial which is being rendered within the _Layout and is strongly typed to @inherits UmbracoViewPage<IBanner> where IBanner is the generated interface of the composition.
However the property @Model.Banners is not acting recursively.
ModelBuilders - recursive composition?
Hi all,
I'm new to the latest ModelBuilders package that has been baked into Umbraco Core but am reviewing it to replace the Umbraco Mapper package that I currently use in a 3+ year old site.
I'm having issues finding how to render a composition property that needs to recursively populate up to the root if no value is set on the current page.
For context, this is a carosel banner, where child pages may or may not select images to show directly, but in which case should default to showing whatever banner images are configured on the root "Home" node.
I have a partial which is being rendered within the _Layout and is strongly typed to
@inherits UmbracoViewPage<IBanner>
where IBanner is the generated interface of the composition.However the property
@Model.Banners
is not acting recursively.Any ideas?
Thanks in advance.
is working on a reply...