cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Configure classification attributes

skotni
Explorer
0 Likes
1,198

Hello Experts,

We have one use case where a specific set of products have dimension i.e. length, width, and height details received in product feed into Hybris. The length unit is not consistent with different products.

Here, some products can have the length in inches while others can have the length in some other units and we have created below classification entities to map the dimension features to products.

ClassificationClass : dimensions ClassificationAttributeUnit: cm, inch, mm and etc received in product feed. However, we were unable to configure the Class attribute assignments to achieve this.

Please help to handle this use case?

Note: Given example is for length attribute, however, I have the similar problem with other attributes.

Accepted Solutions (0)

Answers (1)

Answers (1)

skotni
Explorer
0 Likes

Use the value:unit format while preparing the impex value line for feature.

For E.g.: If we need to preserve width of a product.

 $feature1=@overallWidth[$clAttrModifiers];  
 $catalogVersion=YourCatalogVersion
 INSERT_UPDATE Product;code[unique=true];$catalogVersion;$feature1
                      ;1234;               ;29.9:IN 

geffchang
Active Contributor
0 Likes

Is this the answer? Can you share the macro for $clAttrModifiers?

skotni
Explorer
0 Likes

Here are the additional macros for a feature named overallWidth.

 $productCatalog=YourProductCatalog
 $classificationCatalog=YourCalssificationCatalog
 $catalogVersion=catalogversion(catalog(id[default=$productCatalog]),version[default='Staged'])[unique=true,default=$productCatalog:Staged]
 $clAttrModifiers=system='$classificationCatalog',version='1.0',translator=de.hybris.platform.catalog.jalo.classification.impex.ClassificationAttributeTranslator,lang=en
 $feature1=@overallWidth[$clAttrModifiers];  
 $catalogVersion=YourCatalogVersion