How to define which finder shows the product results on a .phtml page?

How to define which finder shows the product results on a .phtml page?

If there are several Product Parts Finder blocks on a .phtml page, you may differentiate the results by the Finder ID value. When the needed finder is used, the \Amasty\Finder\Controller\Index\Search::execute controller receives the request with the needed ID of the finder. 

Let's imagine we have 2 finders on a page. Once the search is triggered by Finder 2: 



 the \Amasty\Finder\Controller\Index\Search::execute controller will receive the value of '2' for the $finderId variable: 



You can also check each finder's ID in the Admin Panel → Amasty → Product Parts Finder → Product Finders.


      • Related Articles

      • Product Parts Finder API

        1. Amasty\Finder\Api\DropdownRepositoryInterface - class for managing parts finder dropdowns: POST /V1/amasty_finder/dropdown, method="save" - create a dropdown; PUT /V1/amasty_finder/dropdown/:id, method="save" - edit a dropdown; DELETE ...
      • Can the module keep the set selection of the parts finder (i.e. brand/model/year) when switching a category?

        Yes, Product Parts Finder provides the opportunity to apply certain filtering parameters that will not be reset when a customer browses different categories. To enable this functionality, navigate to Stores → Configuration → Amasty Extensions → ...
      • How to fine-tune Elastic Search module for exceptional results?

        If you are experiencing unexpected search results while using our Elastic Search module, please follow these steps to confirm your configuration is correctly set. 1. Elasticsearch Engine Configuration Ensure that the Amasty Elasticsearch option is ...
      • I'd like to sort the search results, is it possible?

        The Elastic Search extension provides the functionality to create relevance rules for moving the position of specific products in the search results. Please find the details about creating relevance rules in our guide. If our Improved Sorting ...
      • How to show locations on the product page?

        With the Store Locator for Magento 2 extension, you may add the store locator section to any page of your site as a widget. Step 1. To create a widget, please go to Content → Widgets and add a new widget. The type should be set to Amasty Store ...