StaticPageCategoryExtension
class StaticPageCategoryExtension extends Twig_Extension
Class StaticPageCategoryExtension is injected as twig.extension.static.page.category service. StaticPageCategoryExtension handles the logic and provides necessary data for managed entity in twig.
Methods
getFunctions()
{@inheritdoc}
mixed
getTreeCategories(string $locale)
Get cached tree content for Static Page Categories
setTreeCategoriesToCache(string $locale)
Set generated tree to cache
mixed
getCategoriesForMegamenu(string $theme, string $locale)
Get cached megamenu content
array|mixed
string
getName()
Returns the name of the extension.
Details
at line 33
__construct(StaticPageCategoryManager $categoryManager)
StaticPageCategoryExtension constructor.
at line 41
getFunctions()
{@inheritdoc}
at line 56
mixed
getTreeCategories(string $locale)
Get cached tree content for Static Page Categories
at line 71
setTreeCategoriesToCache(string $locale)
Set generated tree to cache
at line 85
mixed
getCategoriesForMegamenu(string $theme, string $locale)
Get cached megamenu content
at line 96
array|mixed
getChildrenInOrder(StaticPageCategory $category)
Get category children
at line 110
string
getName()
Returns the name of the extension.