32 self::CATEGORY_FILTER => \Magento\Catalog\Model\Layer\Filter\Category::class,
33 self::ATTRIBUTE_FILTER => \Magento\Catalog\Model\Layer\Filter\Attribute::class,
34 self::PRICE_FILTER => \Magento\Catalog\Model\Layer\Filter\Price::class,
35 self::DECIMAL_FILTER => \Magento\Catalog\Model\Layer\Filter\Decimal::class,
57 $this->filterTypes = array_merge($this->filterTypes,
$filters);
68 if (!count($this->filters)) {
70 $this->objectManager->create($this->filterTypes[self::CATEGORY_FILTER], [
'layer' => $layer]),
72 foreach ($this->filterableAttributes->getList() as
$attribute) {
92 $filter = $this->objectManager->create(
94 [
'data' => [
'attribute_model' =>
$attribute],
'layer' => $layer]
109 if (
$attribute->getAttributeCode() ==
'price') {
115 return $filterClassName;
elseif(isset( $params[ 'redirect_parent']))
createAttributeFilter(\Magento\Catalog\Model\ResourceModel\Eav\Attribute $attribute, \Magento\Catalog\Model\Layer $layer)
getFilters(\Magento\Catalog\Model\Layer $layer)
__construct(\Magento\Framework\ObjectManagerInterface $objectManager, FilterableAttributeListInterface $filterableAttributes, array $filters=[])
getAttributeFilterClass(\Magento\Catalog\Model\ResourceModel\Eav\Attribute $attribute)