当前位置: 首页>>代码示例>>PHP>>正文


PHP ViewModel::__construct方法代码示例

本文整理汇总了PHP中Zend\View\Model\ViewModel::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP ViewModel::__construct方法的具体用法?PHP ViewModel::__construct怎么用?PHP ViewModel::__construct使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Zend\View\Model\ViewModel的用法示例。


在下文中一共展示了ViewModel::__construct方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: __construct

 public function __construct($params = null)
 {
     parent::__construct($params);
     $this->setTemplate($this->_template);
     $this->init();
     $this->widget = $this;
 }
开发者ID:daemonalchemist,项目名称:atp-core,代码行数:7,代码来源:Widget.php

示例2: __construct

 /**
  * @param array $variables
  * @param array $options
  * @param string $template
  */
 public function __construct($variables = null, $options = null, $template = null)
 {
     parent::__construct($variables, $options);
     // May be overloaded by inheriting class
     if (empty($this->template)) {
         $this->template = $template;
     }
 }
开发者ID:andrearruda,项目名称:FormRenderer,代码行数:13,代码来源:Element.php

示例3: __construct

 /**
  * @param array|null $variables
  * @param array|null $options
  */
 public function __construct($variables = null, $options = null)
 {
     parent::__construct($variables, $options);
     $this->setTemplate(static::DEFAULT_TEMPLATE);
     if (!$this->getVariable('textDomain')) {
         $this->setVariable('textDomain', 'default');
     }
 }
开发者ID:gridguyz,项目名称:core,代码行数:12,代码来源:WizardStep.php

示例4: __construct

 public function __construct($config, $sm, $data)
 {
     //Initialize the view
     parent::__construct();
     //Get the widget definitions
     $this->_allWidgets = $config['viz']['widgets'];
     $this->setServiceLocator($sm);
     //Set the template
     $this->setTemplate('atp-viz/widget/container.phtml');
     //Set the data
     foreach ($data as $name => $value) {
         $this->{$name} = $value;
     }
 }
开发者ID:daemonalchemist,项目名称:atp-viz,代码行数:14,代码来源:Container.php

示例5: __construct

 /**
  *
  * @param null|array|\Traversable $variables
  * @param string $htmlTemplate
  * @param string $textTemplate
  */
 public function __construct($htmlTemplate = '', $textTemplate = '', $variables = array())
 {
     parent::__construct($variables);
     $this->mb = (new Mailgun())->MessageBuilder();
     if ($htmlTemplate !== '') {
         $htmlViewModel = new ViewModel($variables);
         $htmlViewModel->setTemplate($htmlTemplate);
         $this->setHtmlViewModel($htmlViewModel);
     }
     if ($textTemplate !== '') {
         $textViewModel = new ViewModel($variables);
         $textViewModel->setTemplate($textTemplate);
         $this->setTextViewModel($textViewModel);
     }
     $this->initFrom();
     $this->initTo();
     $this->initSubject();
     $this->initInlineFiles();
 }
开发者ID:ebittleman,项目名称:mailgun-zf2,代码行数:25,代码来源:MessageViewModel.php

示例6: __construct

 public function __construct()
 {
     parent::__construct();
     $this->setViewData();
 }
开发者ID:SeiYukinariEc,项目名称:ProcessManagement,代码行数:5,代码来源:MemberViewModel.php

示例7: __construct

 public function __construct($userId)
 {
     parent::__construct();
     $this->userId = $userId;
     $this->setViewData();
 }
开发者ID:SeiYukinariEc,项目名称:ProcessManagement,代码行数:6,代码来源:MemberDetailViewModel.php

示例8: __construct

 public function __construct(\Application\Model\Calendar $calendar, $variables = null, $options = null)
 {
     $this->calendar = $calendar;
     parent::__construct($variables, $options);
     $this->setTerminal(true);
 }
开发者ID:Theodia,项目名称:theodia.org,代码行数:6,代码来源:CalendarModel.php

示例9: __construct

 public function __construct($variables = null, $options = null)
 {
     parent::__construct($variables, $options);
 }
开发者ID:Niloofareyjey,项目名称:ellie-ui,代码行数:4,代码来源:Set.php

示例10: __construct

 public function __construct($variables = null, $options = null)
 {
     $variables['name'] = !isset($variables['name']) ? "" : $variables['name'];
     $this->name = $variables['name'];
     parent::__construct($variables, $options);
 }
开发者ID:pderakhshanfar,项目名称:elli-ui,代码行数:6,代码来源:Element.php

示例11: __construct

 /**
  * Constructor
  *
  * @param   string                  $name
  * @param   null|array|Traversable  $variables
  * @param   array|Traversable       $options
  */
 public function __construct($name, $variables = null, $options = null)
 {
     $this->setName($name);
     parent::__construct($variables, $options);
 }
开发者ID:gridguyz,项目名称:core,代码行数:12,代码来源:MetaContent.php

示例12: __construct

 /**
  * Constructor
  *
  * @param  null|array|Traversable $variables
  * @param  array|Traversable $options
  */
 public function __construct($variables = null, $options = null)
 {
     $this->setTemplate('whathood/error/index.phtml');
     parent::__construct($variables, $options);
 }
开发者ID:godentarek,项目名称:whathood,代码行数:11,代码来源:ErrorViewModel.php

示例13: __construct

 /**
  * @param null $variables
  * @param null $options
  */
 public function __construct($variables = null, $options = null)
 {
     $this->terminate = true;
     parent::__construct($variables, $options);
 }
开发者ID:old-town,项目名称:workflow-designer-server,代码行数:9,代码来源:WorkflowDescriptorApiModel.php

示例14: __construct

 /**
  * @param mixed $variables
  * @param string $options
  */
 public function __construct($variables = null, $options = null)
 {
     parent::__construct($variables, $options);
     $this->setTerminal(true);
 }
开发者ID:zhangyuxiao,项目名称:qoros,代码行数:9,代码来源:PartialViewModel.php

示例15: __construct

 /**
  * Constructor
  *
  * @param string $snippetName
  * @param string $snippetIdentifier
  * @param null $variables
  * @param null $options
  */
 public function __construct($snippetName, $snippetIdentifier, $variables = null, $options = null)
 {
     $this->setSnippetName($snippetName);
     $this->setSnippetIdentifier($snippetIdentifier);
     parent::__construct($variables, $options);
 }
开发者ID:ins0,项目名称:zf2-snippster,代码行数:14,代码来源:ViewSnippet.php


注:本文中的Zend\View\Model\ViewModel::__construct方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。