PHPackages                             smoked/filter-manager-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. smoked/filter-manager-bundle

ActiveSymfony-bundle[Utility &amp; Helpers](/categories/utility)

smoked/filter-manager-bundle
============================

Filter manager bundle for product lists (symfony flex version)

v2.1.2(8y ago)02.2kMITPHPPHP ^7.0|^7.1

Since Oct 30Pushed 8y ago1 watchersCompare

[ Source](https://github.com/smoked/FilterManagerBundle)[ Packagist](https://packagist.org/packages/smoked/filter-manager-bundle)[ Docs](http://ongr.io)[ RSS](/packages/smoked-filter-manager-bundle/feed)WikiDiscussions master Synced yesterday

READMEChangelogDependencies (19)Versions (35)Used By (0)

ONGR FilterManagerBundle
========================

[](#ongr-filtermanagerbundle)

Filter manager is used for listing documents. It provides ties between commonly used filtering options and UI elements with Elasticsearch repositories. It is important to mention that filtering is everything what has impact on list, it can be:

- Filtering on specific field value object have (color, country etc.)
- Filtering range (price range, distance from point etc.)
- Documents list pagination. Paging changes representation of list, so it is considered to be filter and is treated like one.
- Documents list sorting. Same as paging - sorting is filter in this bundle.
- Any custom factor which has influence (not always directly visible) on result list. It can exclude, boost, modify some results, collect some metrics or any other action you can imagine.

If you need any help, [stack overflow](http://stackoverflow.com/questions/tagged/ongr)is the preffered and recommended way to ask ONGR support questions.

[![Build Status](https://camo.githubusercontent.com/20bfa1c593f10026891bef443ca990a23ac6a80d1e4864d07579a37cf626970f/68747470733a2f2f7472617669732d63692e6f72672f6f6e67722d696f2f46696c7465724d616e6167657242756e646c652e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/ongr-io/FilterManagerBundle)[![Coverage Status](https://camo.githubusercontent.com/290c694705fa3fa06de2a2d2b86952c7c89bf2c3ebd21414a9cb9c9cb9373fcd/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6f6e67722d696f2f46696c7465724d616e6167657242756e646c652f62616467652e7376673f6272616e63683d6d617374657226736572766963653d676974687562)](https://coveralls.io/github/ongr-io/FilterManagerBundle?branch=master)[![Latest Stable Version](https://camo.githubusercontent.com/12e0af58ade4bb79e6b6852ab7a126bc23bfd472f14cde96a19bddf7628a4cc2/68747470733a2f2f706f7365722e707567782e6f72672f6f6e67722f66696c7465722d6d616e616765722d62756e646c652f762f737461626c65)](https://packagist.org/packages/ongr/filter-manager-bundle)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/01d4d8a71db5e624b0dedcf7d09d913b716094e315c719f48462913dee71788b/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f6f6e67722d696f2f46696c7465724d616e6167657242756e646c652f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/ongr-io/FilterManagerBundle/?branch=master)

Documentation
-------------

[](#documentation)

For online documentation of the bundle [click here](http://docs.ongr.io/FilterManagerBundle). All docs pages are located in `Resources/doc/`.

Installation
------------

[](#installation)

### Step 1: Install FilterManager bundle

[](#step-1-install-filtermanager-bundle)

FilterManager bundle is installed using [Composer](https://getcomposer.org).

```
# You can require any version you need, check the latest stable to make sure you are using the newest version.
$ composer require ongr/filter-manager-bundle "~2.0"
```

> Please note that filter manager requires Elasticsearch bundle, guide on how to install and configure it can be found [here](https://github.com/ongr-io/ElasticsearchBundle).

### Step 2: Enable FilterManager bundle

[](#step-2-enable-filtermanager-bundle)

Enable Filter Manager bundle in your AppKernel:

```
// app/AppKernel.php

public function registerBundles()
{
    $bundles = [
        // ...
        new ONGR\ElasticsearchBundle\ONGRElasticsearchBundle(),
        new ONGR\FilterManagerBundle\ONGRFilterManagerBundle(),
        new \JMS\SerializerBundle\JMSSerializerBundle(),
    ];

    // ...
}
```

### Step 3: Add configuration for manager

[](#step-3-add-configuration-for-manager)

Add minimal configuration for Elasticsearch and FilterManager bundles.

```
# app/config/config.yml

ongr_elasticsearch:
    managers:
        default:
            index:
                hosts:
                    - 127.0.0.1:9200
                index_name: products

ongr_filter_manager:
    managers:
        search_list: #
