'EcorResCategory get childrens x++

I need to get all childrens (and its childrens) for a parent product category

example:

Parent
-- child 1
-- child 2
---- child 2.1
---- child 2.2
-- child 3

I am using the EcoResCategory.getChildren() method but it gets the first children only.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source