コード例 #1
0
 /**
  * @param \ACP3\Core\Application\Event\ControllerActionBeforeDispatchEvent $event
  *
  * @return bool
  */
 private function isInFrontend(ControllerActionBeforeDispatchEvent $event)
 {
     return $event->getControllerArea() === AreaEnum::AREA_FRONTEND && $this->request->getArea() === AreaEnum::AREA_FRONTEND;
 }
コード例 #2
0
 /**
  * ControllerActionDispatchAfterEvent constructor.
  * @param string $serviceId
  * @param Response $response
  */
 public function __construct($serviceId, Response $response)
 {
     parent::__construct($serviceId);
     $this->response = $response;
 }