Class ProductCategoryFieldService
- Namespace
- Dynamicweb.Ecommerce
- Assembly
- Dynamicweb.Ecommerce.dll
public class ProductCategoryFieldService : ICacheStorage<string, IDictionary<string, Field>>, ICacheStorage<string>, ICacheStorage
- Inheritance
-
Product
Category Field Service
- Implements
- Inherited Members
Constructors
ProductCategoryFieldService()
Methods
AddReferenceFields(IEnumerable<string>, string)
Adds reference fields to target category.
Parameters
systemFieldUniqueIds
IEnumerable<string>The field unique ids to be referenced. Get
Unique Id() targetCategoryId
stringTarget category id. Must be common or property category type.
ClearCache()
Resets all keys to the default value for objects stored in the object cache
ClearCache(IEnumerable<string>)
Resets the specified keys to the default value for objects stored in the object cache
Parameters
keys
IEnumerable<string>Keys to reset
ClearCache(string)
Resets the specified key to the default value for objects stored in the object cache
Parameters
key
stringKey to reset
CreateField(string, Category, string, string, string, string, FieldListPresentationType, string)
Creates new category field for the category
public Field CreateField(string id, Category category, string templateTag, string label, string type, string defaultValue, FieldListPresentationType presentation, string description)
Parameters
id
stringField id
category
CategoryThe category
templateTag
stringField template tag
label
stringField label
type
stringField Type
defaultValue
stringField Default value(for list types)
presentation
FieldList Presentation Type Field list presentation type(for list types)
description
stringField description
Returns
CreateField(string, Category, string, string, string, string, FieldListPresentationType, string, bool, bool, bool)
Creates new category field for the category
public Field CreateField(string id, Category category, string templateTag, string label, string type, string defaultValue, FieldListPresentationType presentation, string description, bool allowChangesAcrossLanguages, bool allowChangesAcrossVariants, bool fieldRequired)
Parameters
id
stringField id
category
CategoryThe category
templateTag
stringField template tag
label
stringField label
type
stringField Type
defaultValue
stringField Default value(for list types)
presentation
FieldList Presentation Type Field list presentation type(for list types)
description
stringField description
allowChangesAcrossLanguages
boolAllow changes across languages
allowChangesAcrossVariants
boolAllow changes across variants
fieldRequired
boolField description
Returns
CreateField(string, Category, string, string, string, string, FieldListPresentationType, string, string)
Creates new category field for the category
public Field CreateField(string id, Category category, string templateTag, string label, string type, string defaultValue, FieldListPresentationType presentation, string description, string languageId)
Parameters
id
stringField id
category
CategoryThe category
templateTag
stringField template tag
label
stringField label
type
stringField Type
defaultValue
stringField Default value(for list types)
presentation
FieldList Presentation Type Field list presentation type(for list types)
description
stringField description
languageId
string
Returns
DeleteField(Field)
Deletes the field.
Parameters
theField
FieldThe field to remove.
GetFieldById(string, string)
Gets category field by id and cartegory id
Parameters
Returns
GetFieldsByCategoryId(string)
Parameters
categoryId
string
Returns
GetInheritedCategories(IEnumerable<Group>, bool)
public IEnumerable<Category> GetInheritedCategories(IEnumerable<Group> groups, bool includeProductProperties)
Parameters
groups
IEnumerable<Group>includeProductProperties
bool
Returns
SaveField(Field)
Saves this instance.
Parameters
theField
Field
ShowField(Field, Product)
Return a boolean, which indicates whether or not the field should be shown. This is calculated based on the 'HideIfFieldHasNoValue' and the value of the field.
Parameters
Returns
UpdateReferenceFields(Field)
Update all reference fields by Set
Parameters
theField
Field