PHPackages                             gregosphatos/doctrine-filters-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. [Database &amp; ORM](/categories/database)
4. /
5. gregosphatos/doctrine-filters-bundle

ActiveSymfony-bundle[Database &amp; ORM](/categories/database)

gregosphatos/doctrine-filters-bundle
====================================

Some nice doctrine filters

1.0.2(10y ago)03.5kMITPHPPHP &gt;=5.3.0

Since Aug 27Pushed 10y ago1 watchersCompare

[ Source](https://github.com/GreGosPhaTos/DoctrineFiltersBundle)[ Packagist](https://packagist.org/packages/gregosphatos/doctrine-filters-bundle)[ RSS](/packages/gregosphatos-doctrine-filters-bundle/feed)WikiDiscussions master Synced 2d ago

READMEChangelogDependencies (7)Versions (4)Used By (0)

Overview
========

[](#overview)

[![Build Status](https://camo.githubusercontent.com/3d8e02a6025203ad946fb51096844c6f3ec0ac0ea08554e3c63d223a0faa24a7/68747470733a2f2f7472617669732d63692e6f72672f477265476f73506861546f732f446f637472696e6546696c7465727342756e646c652e737667)](https://travis-ci.org/GreGosPhaTos/DoctrineFiltersBundle)[![Latest Stable Version](https://camo.githubusercontent.com/a4910a1986a8fde9307aa4ed4e1ee7ec86dd8272f22e88d8ae14b95dfd77ee67/68747470733a2f2f706f7365722e707567782e6f72672f677265676f73706861746f732f646f637472696e652d66696c746572732d62756e646c652f76657273696f6e)](https://packagist.org/packages/gregosphatos/doctrine-filters-bundle) [![Total Downloads](https://camo.githubusercontent.com/04b993e67aff18a04df118ba8ca5e194e805201cc70d2c42d61c3ec54f090274/68747470733a2f2f706f7365722e707567782e6f72672f677265676f73706861746f732f646f637472696e652d66696c746572732d62756e646c652f646f776e6c6f616473)](https://packagist.org/packages/gregosphatos/doctrine-filters-bundle) [![Latest Unstable Version](https://camo.githubusercontent.com/5605853916a7ab3b0bbce090890ac0b97109af190022c1023285ea685c93655f/68747470733a2f2f706f7365722e707567782e6f72672f677265676f73706861746f732f646f637472696e652d66696c746572732d62756e646c652f762f756e737461626c65)](https://packagist.org/packages/gregosphatos/doctrine-filters-bundle) [![License](https://camo.githubusercontent.com/9c916380fe668e9763a5079acd8000e2b12aa02705c7e2866331768302cabf49/68747470733a2f2f706f7365722e707567782e6f72672f677265676f73706861746f732f646f637472696e652d66696c746572732d62756e646c652f6c6963656e7365)](https://packagist.org/packages/gregosphatos/doctrine-filters-bundle)

DoctrineFiltersBundle provides integration for [DoctrineFilters](http://doctrine-orm.readthedocs.org/en/latest/reference/filters.html) for your Symfony2 Project.

Installation
============

[](#installation)

### With composer :

[](#with-composer-)

Install composer on Linux / Mac OS

```
curl -sS https://getcomposer.org/installer | php
sudo mv composer.phar /usr/local/bin/composer

```

To install composer on Windows download the installer from [getcomposer.org/download](https://getcomposer.org/download/), execute it and follow the instructions.

[Composer documentation](https://getcomposer.org/doc/)

Add this on your composer.json

```
"require": {
    "gregosphatos/doctrine-filters-bundle": "~1.0"
}
```

Documentation
=============

[](#documentation)

### Record state filter

[](#record-state-filter)

This filter is really usefull for all db recordset that need to be statued (active, inactive). Available for Doctrine ORM and Doctrine mongo ODM :

in your config.yml :

```
orm:
    entity_managers:
      # Your own entity manager collection
      some_em:
        filters:
          state_filter:
              class:   GreGosPhaTos\DoctrineFiltersBundle\Doctrine\Filter\ORM\RecordStateFilter
              enabled: true
```

or

```
doctrine_mongodb:
   document_managers:
    # Your own document manager collection
    some_dm:
      filters:
        state_filter:
          class: GreGosPhaTos\DoctrineFiltersBundle\Doctrine\Filter\ODM\RecordStateFilter
          enabled: true
```

Manually add the configurator in your service.yml :

```
services:
  # ORM
  acme.doctrine.orm.filter.configurator:
    class: GreGosPhaTos\DoctrineFiltersBundle\Doctrine\Filter\ORM\Configurator
    arguments:
      - "@doctrine.orm.entity_manager"
      - "@annotation_reader"
    tags:
      - { name: kernel.event_listener, event: kernel.request }
  # ODM
  acme.doctrine.odm.filter.configurator:
    class: GreGosPhaTos\DoctrineFiltersBundle\Doctrine\Filter\ODM\Configurator
    arguments:
      - "@doctrine_mongodb.odm.document_manager"
      - "@annotation_reader"
    tags:
      - { name: kernel.event_listener, event: kernel.request }
```

Change your entities or documents :

```
use GreGosPhaTos\DoctrineFiltersBundle\Doctrine\Annotation\RecordState;

/**
 * Entity.
 *
 * @RecordState(stateFieldName="state", activeValue="active")
 */
class MyEntity
{
    /**
     * Record state
     *  possible values : active, inactive
     */
    private $state;
}
```

Then all the queries will be filter to get only the active records.

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~1 days

Total

3

Last Release

3962d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/26bf0a267c39025fc5664d378cbed25420646197f9ed7ebed6f3ba656c57540a?d=identicon)[GreGosPhaTos](/maintainers/GreGosPhaTos)

---

Top Contributors

[![GreGosPhaTos](https://avatars.githubusercontent.com/u/3729979?v=4)](https://github.com/GreGosPhaTos "GreGosPhaTos (23 commits)")

---

Tags

Symfony2doctrine2filters

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/gregosphatos-doctrine-filters-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/gregosphatos-doctrine-filters-bundle/health.svg)](https://phpackages.com/packages/gregosphatos-doctrine-filters-bundle)
```

###  Alternatives

[sylius/sylius

E-Commerce platform for PHP, based on Symfony framework.

8.5k5.9M738](/packages/sylius-sylius)[rcsofttech/audit-trail-bundle

Enterprise-grade, high-performance Symfony audit trail bundle. Automatically track Doctrine entity changes with split-phase architecture, multiple transports (HTTP, Queue, Doctrine), and sensitive data masking.

1189.8k](/packages/rcsofttech-audit-trail-bundle)[2lenet/crudit-bundle

The easy like Crud'it Bundle.

1616.4k14](/packages/2lenet-crudit-bundle)[kimai/kimai

Kimai - Time Tracking

4.8k9.0k1](/packages/kimai-kimai)[webonaute/doctrine-fixtures-generator-bundle

Generate Fixture from your existing data in your database. You can specify the Entity name and the IDs you want to import in your fixture.

67184.5k](/packages/webonaute-doctrine-fixtures-generator-bundle)[concrete5/core

Concrete core subtree split

20166.1k52](/packages/concrete5-core)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
