상속: extends Symfony\Component\EventDispatcher\Event
예제 #1
0
 public function onPermissionUpdate(PermissionUpdateEvent $permissionUpdateEvent)
 {
     if ($permissionUpdateEvent->getType() !== SecurityBehavior::class) {
         return;
     }
     $document = $this->documentManager->find($permissionUpdateEvent->getIdentifier());
     $this->searchManager->deindex($document);
 }
예제 #2
0
 /**
  * Removes all FileVersionMetas belonging to the collection, which just got secured.
  *
  * @param PermissionUpdateEvent $event
  */
 public function onPermissionUpdate(PermissionUpdateEvent $event)
 {
     if ($event->getType() !== Collection::class) {
         return;
     }
     foreach ($this->fileVersionMetaRepository->findByCollectionId($event->getIdentifier()) as $fileVersionMeta) {
         $this->searchManager->deindex($fileVersionMeta);
     }
 }