app/Plugin/payjp4/EventSubscriber/ShoppingEventSubscriber.php line 33

Open in your IDE?
  1. <?php
  2. /**
  3.  * This file is part of payjp4
  4.  *
  5.  * Copyright(c) Akira Kurozumi <info@a-zumi.net>
  6.  *
  7.  *  https://a-zumi.net
  8.  *
  9.  * For the full copyright and license information, please view the LICENSE
  10.  * file that was distributed with this source code.
  11.  */
  12. namespace Plugin\payjp4\EventSubscriber;
  13. use Eccube\Event\TemplateEvent;
  14. use Symfony\Component\EventDispatcher\EventSubscriberInterface;
  15. class ShoppingEventSubscriber implements EventSubscriberInterface
  16. {
  17.     /**
  18.      * @inheritDoc
  19.      */
  20.     public static function getSubscribedEvents()
  21.     {
  22.         // TODO: Implement getSubscribedEvents() method.
  23.         return [
  24.             'Shopping/index.twig' => 'onTemplateShoppingIndex'
  25.         ];
  26.     }
  27.     public function onTemplateShoppingIndex(TemplateEvent $event)
  28.     {
  29.         $event->addSnippet('@payjp4/Shopping/credit.twig');
  30.     }
  31. }