app/Plugin/Noshidelivery/NoshideliveryEvent.php line 44

Open in your IDE?
  1. <?php
  2. /*
  3.  * This file is part of EC-CUBE
  4.  *
  5.  * Copyright(c) LOCKON CO.,LTD. All Rights Reserved.
  6.  *
  7.  * http://www.lockon.co.jp/
  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\Noshidelivery;
  13. use Eccube\Event\TemplateEvent;
  14. use Symfony\Component\EventDispatcher\EventSubscriberInterface;
  15. class NoshideliveryEvent implements EventSubscriberInterface
  16. {
  17.     public static function getSubscribedEvents()
  18.     {
  19.         return [
  20.             'Shopping/index.twig' => 'onNoshideliveryShopping',
  21.             'Shopping/confirm.twig' => 'onNoshideliveryConfirm',
  22.             '@admin/Order/edit.twig' => 'onAdminNoshideliveryEdit',
  23.             '@admin/Order/shipping.twig' => 'onAdminNoshideliveryShipping',
  24.             'Mypage/history.twig' => 'onNoshideliveryHistory',
  25.         ];
  26.     }
  27.     public function onNoshideliveryShopping(TemplateEvent $event)
  28.     {
  29.         $event->addSnippet('@Noshidelivery/front/add_shopping.twig');
  30.     }
  31.     
  32.     public function onNoshideliveryConfirm(TemplateEvent $event)
  33.     {
  34.         $event->addSnippet('@Noshidelivery/front/add_confirm.twig');
  35.     }
  36.     
  37.     public function onAdminNoshideliveryEdit(TemplateEvent $event)
  38.     {
  39.         $event->addSnippet('@Noshidelivery/admin/add_edit.twig');
  40.     }
  41.     
  42.     public function onAdminNoshideliveryShipping(TemplateEvent $event)
  43.     {
  44.         $event->addSnippet('@Noshidelivery/admin/add_shipping.twig');
  45.     }
  46.     
  47.     public function onNoshideliveryHistory(TemplateEvent $event)
  48.     {
  49.         $event->addSnippet('@Noshidelivery/front/add_history.twig');
  50.     }
  51.     
  52. }