Skip to content

Commit

Permalink
Don't use dev-master branch of DoctrineBundle but still use entity li…
Browse files Browse the repository at this point in the history
…stener features
  • Loading branch information
maxailloud committed Mar 12, 2014
1 parent 9b606ca commit 1afe90e
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
4 changes: 4 additions & 0 deletions DependencyInjection/Compiler/DoctrineEntityListenerPass.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,15 @@

use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Reference;

class DoctrineEntityListenerPass implements CompilerPassInterface
{
public function process(ContainerBuilder $container)
{
$config = $container->getDefinition('doctrine.orm.default_configuration');
$config->addMethodCall('setEntityListenerResolver', array(new Reference('claroline.doctrine.entity_listener_resolver')));

$definition = $container->getDefinition('claroline.doctrine.entity_listener_resolver');
$services = $container->findTaggedServiceIds('doctrine.entity_listener');

Expand Down
3 changes: 1 addition & 2 deletions Resources/config/suggested/doctrine_prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,4 @@ doctrine:
filters:
softdeleteable:
class: Gedmo\SoftDeleteable\Filter\SoftDeleteableFilter
enabled: true
entity_listener_resolver: claroline.doctrine.entity_listener_resolver
enabled: true
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"symfony/swiftmailer-bundle": "~2.3",
"symfony/monolog-bundle": "~2.3",
"doctrine/orm": "~2.4.0",
"doctrine/doctrine-bundle": "dev-master",
"doctrine/doctrine-bundle": "1.2.0",
"twig/extensions": "~1.0.0",
"sensio/distribution-bundle": "~2.3.4",
"sensio/framework-extra-bundle": "~2.3.4",
Expand Down

0 comments on commit 1afe90e

Please sign in to comment.