protected override IEnumerable <string> GetEmbeddableContentTypes(IGraphSyncContext context)
        {
            IGraphSyncContext rootContext = context;

            while (rootContext.ParentContext != null)
            {
                rootContext = rootContext.ParentContext;
            }

            return(new string[]
            {
                rootContext.ContentItem.Content[nameof(TaxonomyPart)][
                    TaxonomyPartGraphSyncer.TermContentTypePropertyName]
            });
        }
示例#2
0
 protected override IEnumerable <string> GetEmbeddableContentTypes(IGraphSyncContext context)
 {
     return(_contentDefinitionManager.ListTypeDefinitions()
            .Where(t => t.GetSettings <ContentTypeSettings>().Stereotype == "Widget")
            .Select(t => t.Name));
 }
示例#3
0
        protected override IEnumerable <string> GetEmbeddableContentTypes(IGraphSyncContext context)
        {
            BagPartSettings bagPartSettings = context.ContentTypePartDefinition.GetSettings <BagPartSettings>();

            return(bagPartSettings.ContainedContentTypes);
        }
        public void AddChildContext(IGraphSyncContext graphSyncContext)
        {
            _logger.LogDebug("Adding child to {Context}: {ChildContext}.", ToString(), graphSyncContext.ToString());

            _childContexts.Add(graphSyncContext);
        }