public function __construct($config = []) { parent::__construct($config); if (!$this->transaction instanceof OrderTransaction) { $this->transaction = new OrderTransaction(); } }
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); }
public function __construct($config = []) { $this->_config = $config; try { parent::__construct($config); } catch (WidgetMissedIdException $e) { throw $e; } catch (\Exception $e) { $this->processException($e); } }
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 }
public function __construct(BuildingFinderInterface $buildingFinder, $config = []) { $this->buildingFinder = $buildingFinder; parent::__construct($config); }
public function __construct(BlogFinder $finder, $config = []) { $this->finder = $finder; parent::__construct($config); }