Skip to content

Instantly share code, notes, and snippets.

View gmuehl's full-sized avatar

Guido Mühlwitz gmuehl

View GitHub Profile
@baptistedonaux
baptistedonaux / DeletedFilter.php
Created February 19, 2015 11:32
Soft Delete Symfony/Doctrine
<?php
namespace Namespace\MyBundle\Repository\Filters;
use Doctrine\ORM\Mapping\ClassMetaData;
use Doctrine\ORM\Query\Filter\SQLFilter;
class DeletedFilter extends SQLFilter
{
public function addFilterConstraint(ClassMetadata $targetEntity, $targetTableAlias)
{