From a DD4T project, I'm trying to get the children from an OrganizationalItem but the object doesn't have that property. I'm runing a MVC project and I'm trying to get the page from the controller on the web application.
public class NavigationService
{
private readonly IPageFactory _pageFactory;
public NavigationService(IpageFactory pagefactory)
{
_pageFactory = pageFactory;
}
private void GetPagesFromStructureGroup(NavigationItem navItem)
{
if (!_pageFactory.TryGetPage(navItem.Tcm, out var StructureGroup))
return null;
var structureGroup = StructureGroup.StructureGroup;
}
}