mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-24 10:23:17 +00:00
Merge pull request #1522 from jygaulier/PHRAS-741_back-office-events
#PHRAS-741 #time 10m
This commit is contained in:
@@ -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);
|
||||
|
||||
@@ -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'];
|
||||
}
|
||||
}
|
||||
|
||||
@@ -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)
|
||||
|
||||
@@ -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
|
||||
)
|
||||
)
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user