Ejemplo n.º 1
0
        public PropertyTypeBuilder <ContentTypeBuilder> AddPropertyType()
        {
            var builder = new PropertyTypeBuilder <ContentTypeBuilder>(this);

            _noGroupPropertyTypeBuilders.Add(builder);
            return(builder);
        }
Ejemplo n.º 2
0
        public PropertyTypeBuilder <PropertyBuilder> AddPropertyType()
        {
            _propertyType = null;
            var builder = new PropertyTypeBuilder <PropertyBuilder>(this);

            _propertyTypeBuilder = builder;
            return(builder);
        }
Ejemplo n.º 3
0
        public static ContentType CreateSimpleTagsContentType(string alias, string name, IContentType parent = null, bool randomizeAliases = false, string propertyGroupName = "Content", int defaultTemplateId = 1)
        {
            ContentType contentType = CreateSimpleContentType(alias, name, parent, randomizeAliases: randomizeAliases, propertyGroupName: propertyGroupName, defaultTemplateId: defaultTemplateId);

            PropertyType propertyType = new PropertyTypeBuilder()
                                        .WithPropertyEditorAlias(Constants.PropertyEditors.Aliases.Tags)
                                        .WithValueStorageType(ValueStorageType.Nvarchar)
                                        .WithAlias(RandomAlias("tags", randomizeAliases))
                                        .WithName("Tags")
                                        .WithDataTypeId(Constants.DataTypes.Tags)
                                        .WithSortOrder(99)
                                        .Build();

            contentType.AddPropertyType(propertyType);

            return(contentType);
        }
Ejemplo n.º 4
0
 public PropertyBuilder WithPropertyType(IPropertyType propertyType)
 {
     _propertyTypeBuilder = null;
     _propertyType        = propertyType;
     return(this);
 }