cancel
Showing results for 
Search instead for 
Did you mean: 

how can i get all supercategories of perticular product from parent to child order?

0 Kudos

I want get all super categories in sorting order(Like parent to child or child to parent).Im using this method getting all super categories. final Collection allsuperCategories = categoryModel.getAllSupercategories();

But im getting all supercategories but not in order.

Former Member
0 Kudos

Which version of hybris is being used?. As of 5.5 i can see some useful methods in CategoryService that is worth a try for the above especially the getCategoryPathForProduct method

Accepted Solutions (0)

Answers (1)

Answers (1)

0 Kudos

Hi Niranjan,

I'm using hybris-commerce-suite-5.1.1.1 version.. I abserved there is one method is there "getCategoryPathForProduct(product, includeOnlyCategories)". here what is this parameter "includeOnlyCategories". Can u please explain me?

Former Member
0 Kudos

You can pass it as empty or null, unless you want to restrict your results for specific category type, by passing in the runtime class of the types as an array.