local/modules/CreditNote/Hook/Back/MainHook.php line 20

  1. <?php
  2. /*************************************************************************************/
  3. /*      This file is part of the module CreditNote                                   */
  4. /*                                                                                   */
  5. /*      For the full copyright and license information, please view the LICENSE.txt  */
  6. /*      file that was distributed with this source code.                             */
  7. /*************************************************************************************/
  8. namespace CreditNote\Hook\Back;
  9. use CreditNote\CreditNote;
  10. use Thelia\Core\Event\Hook\HookRenderEvent;
  11. use Thelia\Core\Hook\BaseHook;
  12. /**
  13.  * @author Gilles Bourgeat >gilles.bourgeat@gmail.com>
  14.  */
  15. class MainHook extends BaseHook
  16. {
  17.     public function onMainFooterJs(HookRenderEvent $event)
  18.     {
  19.         $event->add($this->render(
  20.             'hook/main.footer-js.html',
  21.             $event->getArguments() + [
  22.                 'admin_current_location' => ($this->getRequest()->get('_route') == 'creditnote.list' 'credit-note' '')
  23.             ]
  24.         ));
  25.     }
  26. }