DefaultPageXML in custom Route

What type of XML can I put in the DefaultPageXML param of a custom Route?  I exported a page, but not sure if it needs the entire export or only what is in the ContentFragmentPage node?

controller.AddPage(page.PageKey, page.RoutePath, null, null, page.PageKey, new PageDefinitionOptions() {DefaultPageXml ParseContext = ParseCMSPageContext });

 <contentFragmentPage pageName="family-services" isCustom="false" layout="Content" themeType="0c647246-6735-42f9-875d-c8b991fe739b" lastModified="2019-05-30 05:50:02Z">
      <regions>
        <region regionName="Content">
          <contentFragments>
            <contentFragment type="Telligent.Evolution.ScriptedContentFragments.ScriptedContentFragment, Telligent.Evolution.Platform::50c816b46c7647d5a7cea85b3f47d4d6" showHeader="True" cssClassAddition="top-border with-spacing with-header responsive-1" isLocked="False" configuration="title=Family%20Services&html=%3Cp%3EFamily%20Services%20content%20goes%20here.%3C%2Fp%3E&backgroundImage=&width=page&cssClass=" />
          </contentFragments>
        </region>
      </regions>
      <contentFragmentTabs />
    </contentFragmentPage>

Parents Reply
  • What should be in there?  

            private void ParseCMSPageContext(PageContext context)
            {
                var items = context.ContextItems.GetAllContextItems();
                int currentGroupId = Apis.Get<IGroups>().Root.Id.Value;
    
                foreach (var item in items)
                {
                    if (item.ContentTypeId.Equals(Apis.Get<IGroups>().ContentTypeId))
                    {
                        currentGroupId = Convert.ToInt32(item.Id);
                    }
                }
                var group = Apis.Get<IGroups>().Get(new GroupsGetOptions { Id = currentGroupId });
                if (group != null)
                {
                    Data.CMSPageDataProvider db = new Data.CMSPageDataProvider();
                    var page = db.GetCMSPage(currentGroupId, context.PageName);
                    if (page != null)
                    {
                        Telligent.Evolution.Extensibility.Urls.Version1.ContextItem contextItem = new Telligent.Evolution.Extensibility.Urls.Version1.ContextItem()
                        {
                            TypeName = "CMSPage",
                            Id = page.Id.ToString(),
                            ApplicationId = group.ApplicationId,
                            ApplicationTypeId = Apis.Get<IGroups>().ApplicationTypeId,
                            ContainerId = group.ContainerId,
                            ContainerTypeId = Apis.Get<IGroups>().ContainerTypeId,
                            ContentTypeId = Components.CMSPages.CMS_PAGE_CONTENT_TYPE_ID,
                            ContentId = null
                        };
    
                        context.ContextItems.Put(contextItem);
                    }
                }
            }

Children