Esempio n. 1
0
 public function __construct($config = [])
 {
     parent::__construct($config);
     if (!$this->transaction instanceof OrderTransaction) {
         $this->transaction = new OrderTransaction();
     }
 }
Esempio n. 2
0
 public function __construct($config = [])
 {
     //by default both opengraph and microdata are enabled, disable if ['enable' => false] was explicitly passed to widget
     $config['og'] = array_merge($this->og, isset($config['og']) ? $config['og'] : []);
     $config['md'] = array_merge($this->md, isset($config['md']) ? $config['md'] : []);
     parent::__construct($config);
 }
Esempio n. 3
0
 public function __construct($config = [])
 {
     $this->_config = $config;
     try {
         parent::__construct($config);
     } catch (WidgetMissedIdException $e) {
         throw $e;
     } catch (\Exception $e) {
         $this->processException($e);
     }
 }
Esempio n. 4
0
 public function __construct($config = [])
 {
     if (count($config) > 0) {
         $this->action = empty($config['action']) ? \Yii::$app->controller->action->id : $config['action'];
         $this->selector = empty($config['selector']) ? 'ctype' : $config['selector'];
         $this->ctype = empty($config[$this->selector]) ? '' : $config[$this->selector];
     } else {
         $this->action = \Yii::$app->controller->action->id;
         $this->ctype = !empty(\Yii::$app->getRequest()->getQueryParam($this->selector)) ? \Yii::$app->getRequest()->getQueryParam($this->selector) : 'page';
     }
     parent::__construct();
     // TODO: Change the autogenerated stub
 }
Esempio n. 5
0
 public function __construct(BuildingFinderInterface $buildingFinder, $config = [])
 {
     $this->buildingFinder = $buildingFinder;
     parent::__construct($config);
 }
Esempio n. 6
0
 public function __construct(BlogFinder $finder, $config = [])
 {
     $this->finder = $finder;
     parent::__construct($config);
 }