Customer-Product Attribute-Filter

Introduction

The "catalog product customer attribute filter"-extension for the Magento2.x supports dynamic product filtering via matching product- and customer-attribute values. Products with matching  values are available in the storefront - products with non matching values will be hidden to the customer. 

E.g. If you want to show products to customers with matching languages, countries or sizes only.

Module

Extension-Name: enobis/module-catalog-product-customer-attribute-filter

Latest stable version

1.1.1

Install & Update

First you need to add our private repo to your composer.json of your magento installation:

composer config repositories.enobis-your-reponame composer https://satis.enobis.de/customers/your-reponame/

Important: All repos are secured by an ip-protection or an user-authentication. Access Credentials are provided by us!

To install the CHILIconnector-extension use composer via ssh:

composer require enobis/extension-name

To update the CHILIconnector-extension use composer via ssh:

composer update enobis/extension-name

Afterwards you have to complete your Magento2.x installation by

php bin/magento setup:upgrade
php bin/magento setup:di:compile
php bin/magento setup:static-content:deploy
php bin/magento cache:clean
php bin/magento indexer:reindex

Changelog & Roadmap

  • Changelog

    • 1.1.1 optimization - add seperate indexes for products and customers to speed up the indexing process
    • 1.1.0 optimization - magento 2.4.3 compatibility, extensive debug logging can be turned on and off, optimization avoid entries for products that are not enabled anywhere, optimization for multi website shops with disabled module on some websites, avoid entries for customers and products that are only on non filtered websites
    • 1.0.1 optimization - Allow html in "Customer Attribute Filter Responsible" attribute output, Add wysiwyg functionality to "Customer Attribute Filter Responsible" attribute
    • 1.0.0 Initial Release
  • Roadmap

    • Filter-Attribute-Configuration from backend. Right now the filter attributes must be configured by a xml-configuration file in the theme folder.
    • Filtering with activated Caches (Catalog_Category, Catalog_Product, Catalog_Search) - right now, they must be deactivated to filter correctly.
    • "Stop Full Reindex Process" - Change to "Global Scope" in Backend

Feature-Overview

  • Filtering

    The filter mechanism is based on matching customer- and product-attribute values.

    Important:

    • Matching attribute value: Product is available in frontend
    • Non machting attribute: Product is not available in frontend
    • Without values (at customer and product) no filtering is active.
    • Only "Dropdown" and "MultipleSelect"-Values are supported.
    • Filter uses the string of the values (Admin-Values).
    • The combination of several attributes as dynamic filters is possible. Each filter-attribute will be interpreted as "and"-filter.
    • Filtering is based on an index table (entries are created via different indexing mechanism from the backend or console)

    Filtered products will be hidden in 

    • catalog list / grid view
    • catalog search view
    • product detail page (configurable, bundle, grouped products)
  • Indexing

    The dynamic filtering is based on an index table, which contains the "visibility" of the product. The table entries are created by different indexing mechnism

    • Manual indexing
      • by console (complete indexing for all products and all customers)
      • by backend-function (complete indexing for all products and all customers)
    • Automatic indexing
      • after customer login (partial indexing for the customer)
      • after saving the customer (partial indexing for the customer and all products)
      • after saving the product (partial indexing for the products and all customers)

Configuration

To activate the dynamic filtering mechanism at least two attributes (product, customer) with matching "attribute_codes" and "attribute values" are needed. The attribute_code must be provided in the configuration-xml-file in your theme.

Example: app/design/frontend/Magento/luma_child/Enobis_CatalogProductCustomerAttributeFilter/etc/catalog_product_customer_attribute_filter.xml

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:module:Enobis_CatalogProductCustomerAttributeFilter:etc/catalog_product_customer_attribute_filter.xsd">
<attributes>
<attribute name="EAV_ATTRIBUTE_CODE" />
</attributes>
</config>

Important: Only Dropdown and MultipleSelect-Attributes are supported for filtering!

Please note: Multiple Attributes can be provided too.

  • Stores->Configuration->CHILI->CHILI-My Document

    OptionTypeDescriptionScope
    EnableYes, No (Default)Enable FilterSystem->Website
    Display Parent Products even all Child Products are filteredYes, No (Default)Display the Parent Product (e.g. Configurable Product) even all child products are filtered. By default the parent product will be filtered too. If it's enabled the parent product is shown in e.g. product listings etc.System->Website
    Hide filtered Child ProductsYes (Default), No

    Hides (default behaviour) the child product if it's filtered. If disabled, the filtered products will be shown as "out of stock" / "not available"

    System->Website
    Disable Full ReindexYes, No (Default)Disables the full reindex mechanism from the backend. System->Global
    Stop Full Reindex ProcessActionStops the reindex processSystem->Storeview (@Todo: Global Scope)
    Enable Debug LoggingYes, No (Default)Enables a debugging log. Debug log available at "/var/logs/debug.log"System->Global

    If everything is setup correctly, your configuration will be saved and you are now able to access some enviromental data in the other configuration tabs.

Prerequisites

Our extensions are not available via the magento-marketplace or packagist.org! The extensions are only available via a (private) repository!

In order to get access, a valid license-agreement is required!

If you have no access to our repositories, please contact us!

Addons

Not enough features? Then get in touch with our [addons]

Support

If you need help using the CHILIconnector, please get in touch with us by sending an email to support@enobis.de.

^Top Copyright © 2021 - enobis GmbH - All rights reserved.