Пример #1
0
 public function init()
 {
     parent::init();
     $currency = Shopware()->Db()->fetchRow('SELECT templatechar as sign, (symbol_position = 16) currencyAtEnd
         FROM s_core_currencies
         WHERE standard = 1');
     $this->View()->assign('analyticsCurrency', $currency);
 }
Пример #2
0
 /**
  * Initials the script renderer and handles the json request.
  * If the internal customer repository isn't initialed the
  * repository is initialed.
  *
  * @codeCoverageIgnore
  * @return void
  */
 public function init()
 {
     if (!$this->Request()->getActionName() || in_array($this->Request()->getActionName(), array('index', 'load'))) {
         $this->View()->addTemplateDir('.');
         $this->Front()->Plugins()->ScriptRenderer()->setRender();
         Shopware()->Plugins()->Backend()->Auth()->setNoAuth();
     } else {
         parent::init();
     }
 }
Пример #3
0
 /**
  * Default init method
  *
  * @codeCoverageIgnore
  * @return void
  */
 public function init()
 {
     parent::init();
     if (!is_null(self::$testRepository)) {
         $this->repository = self::$testRepository;
     } else {
         $this->repository = Shopware()->Models()->Banner();
     }
     $this->namespace = Shopware()->Snippets()->getNamespace('backend/banner/banner');
 }
Пример #4
0
 /**
  * This function add the template directory and register the Shopware_Components namespace
  */
 public function init()
 {
     $this->setMaxExecutionTime();
     Shopware()->Loader()->registerNamespace('Shopware_Components', dirname(__FILE__) . '/../../Components/');
     $this->View()->addTemplateDir(dirname(__FILE__) . "/../../Views/");
     parent::init();
 }
Пример #5
0
 /**
  * Setup Translation Component
  *
  * @return void
  */
 public function init()
 {
     parent::init();
     $this->translation = new Shopware_Components_Translation();
 }
Пример #6
0
 /**
  * Loads auth and script renderer resource
  */
 public function init()
 {
     Shopware()->Plugins()->Backend()->Auth()->setNoAuth();
     parent::init();
 }
Пример #7
0
 /**
  * Adding local template directory to smarty template scope
  */
 public function init()
 {
     $this->View()->addTemplateDir(dirname(__FILE__) . "/../../Views/");
     parent::init();
 }
Пример #8
0
 /**
  * Deactivates the authentication for the performOrderRedirect action
  * This is used in the performOrder action
  */
 public function init()
 {
     if (in_array($this->Request()->getActionName(), array('performOrderRedirect'))) {
         Shopware()->Plugins()->Backend()->Auth()->setNoAuth();
     }
     parent::init();
 }
 /**
  * {@inheritdoc}
  */
 public function init()
 {
     $this->plugin = $this->get('plugins')->Frontend()->SwagPaymentPaypal();
     parent::init();
 }
Пример #10
0
 /**
  * Initialisation of the controller.
  * Throws an exception is the model property isn't configured.
  *
  * @throws Exception
  */
 public function init()
 {
     if (empty($this->model)) {
         throw new Exception('The `model` property of your PHP controller is not configured!');
     }
     parent::init();
 }