Merge pull request #1522 from jygaulier/PHRAS-741_back-office-events

#PHRAS-741 #time 10m
This commit is contained in:
jygaulier
2015-10-05 17:16:58 +02:00
4 changed files with 13 additions and 5 deletions

View File

@@ -52,6 +52,14 @@ abstract class Command extends SymfoCommand implements CommandInterface
return $logger;
})
);
$this->container['dispatcher'] = $this->container->share(
$this->container->extend('dispatcher', function ($dispatcher, Application $app) {
$dispatcher->addSubscriber($app['phraseanet.bo-events-subscriber']);
return $dispatcher;
})
);
}
return $this->doExecute($input, $output);

View File

@@ -11,8 +11,8 @@ class CollectionUnmounted extends CollectionRelated
return $this->args['coll_id'];
}
public function getName()
public function getCollName()
{
return $this->args['name'];
return $this->args['coll_name'];
}
}

View File

@@ -12,7 +12,7 @@
namespace Alchemy\Phrasea\SearchEngine\Phrasea;
use Alchemy\Phrasea\Application;
use Alchemy\Phrasea\Core\Event\CollectionCreateEvent;
use Alchemy\Phrasea\Core\Event\CollectionCreated;
use Alchemy\Phrasea\Core\Event\PostAuthenticate;
use Alchemy\Phrasea\Core\PhraseaEvents;
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
@@ -31,7 +31,7 @@ class PhraseaEngineSubscriber implements EventSubscriberInterface
$event->getUser()->ACL()->inject_rights();
}
public function onCollectionCreate(CollectionCreateEvent $event)
public function onCollectionCreate(CollectionCreated $event)
{
$sql = 'SELECT u.usr_id, c.session_id
FROM (usr u, Sessions s, basusr b)

View File

@@ -625,7 +625,7 @@ class collection implements cache_cacheableInterface
null, // the coll is not available anymore
array(
'coll_id'=>$old_coll_id,
'name'=>$old_name
'coll_name'=>$old_name
)
)
);