Jaa


Properties in the catalog system .... Part II

Extending Property definitions   

You can extend property definitions by adding user defined attributes. For eg you can add a user defined boolean attribute named IsActive to mark a property as being active or not. User defined attributes to property definitions can be added by using the CatalogManager.AddPropertyAttribute method.

 

Multilingual support for properties is provided by allowing the ability to associate display names and default values in multiple languages and also allowing properties to be marked multilingual so that they can contain product and category data in multiple languages.

    In order to associate a display name in a particular language you have to add a user defined attribute named DisplayName_<languagecode> using the CatalogManager.AddPropertyAttribute method. For eg you can add an attribute named DisplayName_en-US to store display names for the en-US culture.

    Default values for multilingual string, filepath and enumeration properties can be stored by adding a user defined attribute named u_defaultvalue_<languagecode> using the CatalogManager.AddPropertyAttribute method. For eg you can add an attribute named u_defaultvalue_en-US to store default values for multilingual string properties in the en-US culture.

    You can also mark a property to be multilingual by setting it's LanguageSensitive attribute to true. The LanguageSensitive attribute can be set for properties of the type string, filepath, enumeration and text only.

 

Multiple Choice properties are properties with the enumeration datatype which have a set of predefined values for them. One of these values can also be marked as the default value for that property. When used in a product these properties can have only one of the predefined values. For eg you can create a multiple choice Color property which has Red, Green and Blue as predefined values. For multilingual properties, it is possible to define the set of predefined values for each language. You can add values to an enumeration property by calling the CatalogManager.AddPropertyValue method.