/** * Get view helper configuration. * * @return array */ public function getViewHelperConfig() { return ['factories' => ['acl' => function ($sm) { $locator = $sm->getServiceLocator(); $helper = new \Application\View\Helper\Acl(); $helper->setServiceLocator($locator); return $helper; }, 'scriptUrl' => function ($sm) { $helper = new \Application\View\Helper\ScriptUrl(); return $helper; }, 'moduleIsActive' => function ($sm) { $locator = $sm->getServiceLocator(); $helper = new \Application\View\Helper\ModuleIsActive(); $helper->setServiceLocator($locator); return $helper; }, 'fileUrl' => function ($sm) { $locator = $sm->getServiceLocator(); $helper = new \Application\View\Helper\FileUrl(); $helper->setServiceLocator($locator); return $helper; }, 'infima' => function ($sm) { $locator = $sm->getServiceLocator(); $helper = new \Application\View\Helper\Infima(); $helper->setLegacyService($locator->get('application_service_legacy')); return $helper; }]]; }
/** * Get view helper configuration. * * @return array */ public function getViewHelperConfig() { return array('factories' => array('acl' => function ($sm) { $locator = $sm->getServiceLocator(); $helper = new \Application\View\Helper\Acl(); $helper->setServiceLocator($locator); return $helper; }, 'scriptUrl' => function ($sm) { $helper = new \Application\View\Helper\ScriptUrl(); return $helper; }, 'isAllowed' => function ($sm) { $locator = $sm->getServiceLocator(); $helper = new \Application\View\Helper\Acl(); $helper->setServiceLocator($locator); return $helper; })); }