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


PHP Zend_Form_Element_Select::__construct方法代码示例

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


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

示例1: __construct

 public function __construct($spec, $options = array())
 {
     $options = array_merge($options, array('disableLoadDefaultDecorators' => true));
     parent::__construct($spec, $options);
     $this->_decorator = new Monkeys_Form_Decorator_Composite();
     $this->addDecorator($this->_decorator);
 }
开发者ID:sdgdsffdsfff,项目名称:auth-center,代码行数:7,代码来源:Language.php

示例2: __construct

 public function __construct($spec, $options = NULL)
 {
     if ($spec instanceof BuggyPress_Issue) {
         $this->_issue = $spec;
         $spec = self::FIELD_NAME;
     }
     parent::__construct($spec, $options);
 }
开发者ID:jbrinley,项目名称:BuggyPress,代码行数:8,代码来源:BuggyPress_Form_Element_IssuePriority.php

示例3: __construct

 public function __construct($spec = null, $options = null)
 {
     parent::__construct($spec, $options);
     if ($options == 'everyFifteen') {
         self::_buildTimeforEveryFifteen();
     }
     return $this;
 }
开发者ID:AlexanderMazaletskiy,项目名称:gym-Tracker-App,代码行数:8,代码来源:DateTime.php

示例4: __construct

 public function __construct($spec, $aOptions = array())
 {
     if (isset($aOptions['ajax'])) {
         $this->_ajax = $aOptions['ajax'];
         unset($aOptions['ajax']);
         $this->setRegisterInArrayValidator(false);
     }
     parent::__construct($spec, $aOptions);
 }
开发者ID:netixx,项目名称:Stock,代码行数:9,代码来源:Select.php

示例5: __construct

 public function __construct($spec = null, $options = null, $values, $required = false)
 {
     parent::__construct($spec, $options);
     $this->addFilter('StringTrim')->setRequired($required)->setLabel($options['label'])->setAttrib('class', $options['class'])->setRegisterInArrayValidator(false)->setDescription(isset($options['desc']) ? $options['desc'] : null)->addMultiOptions($values);
     if (!isset($options['style']) || $options['style'] != 'none') {
         $this->setDecorators(array(new vkNgine_Form_Element_Decorator_Text()));
     }
     if (isset($options['removeDecorators'])) {
         $this->removeDecorator('HtmlTag')->removeDecorator('Label');
     }
 }
开发者ID:AlexanderMazaletskiy,项目名称:gym-Tracker-App,代码行数:11,代码来源:Select.php

示例6: __construct

 public function __construct($spec, $options = null)
 {
     $this->addMultiOption("", "");
     $groups = new Snep_GruposRamais();
     $extengroups = array();
     foreach ($groups->getAll() as $group) {
         $extengroups[$group['id_extensiongroup']] = $group['ds_name'];
     }
     $this->addMultiOptions($extengroups);
     parent::__construct($spec, $options);
 }
开发者ID:rootzig,项目名称:SNEP,代码行数:11,代码来源:ExtensionGroup.php

示例7: __construct

 /**
  * Определяем опции мультиселеста и дергаем родительский конструктор
  *
  * @param mixed $spec
  * @param array $options
  */
 public function __construct($spec, $options = null)
 {
     if (isset($options['multiple']) && (bool) $options['multiple'] === true) {
         $this->_isArray = true;
         $this->multiple = 'multiple';
     }
     /**
      * Инициализируем родительский конструктор
      */
     parent::__construct($spec, $options);
 }
开发者ID:ei-grad,项目名称:phorm,代码行数:17,代码来源:Chosen.php

示例8: __construct

 public function __construct($spec, $options = null)
 {
     $this->addMultiOption("", "");
     $pickupgroup = new Snep_PickupGroups_Manager();
     $pickupgroups = array();
     foreach ($pickupgroup->fetchAll() as $key => $val) {
         $pickupgroups[$val->id_pickupgroup] = $val->ds_name;
     }
     $this->addMultiOptions($pickupgroups);
     parent::__construct($spec, $options);
 }
开发者ID:rootzig,项目名称:SNEP,代码行数:11,代码来源:PickupGroup.php

示例9: __construct

 public function __construct($spec, $options = null)
 {
     foreach (PBX_Trunks::getAll() as $trunk) {
         $data[$trunk->getId()] = $trunk->getName();
     }
     if ($data != null) {
         $this->addMultiOptions($data);
     } else {
         $this->addMultiOption(null, '');
     }
     parent::__construct($spec, $options);
 }
开发者ID:rootzig,项目名称:SNEP,代码行数:12,代码来源:Trunk.php

示例10: __construct

 public function __construct($spec = '', $options = '')
 {
     parent::__construct($spec, $options);
     $table = new KeyTable();
     $select = $table->select();
     $select->order(KeyTable::COL_FILENAME);
     $rowset = $table->fetchAll($select);
     $array = $rowset->toArray();
     $optArray = array(null => 'Please select');
     foreach ($array as $value) {
         $optArray = $optArray + array($value[KeyTable::COL_ID] => $value[KeyTable::COL_FILENAME] . ' (' . $value[KeyTable::COL_NAME] . ')');
     }
     $this->setMultiOptions($optArray);
 }
开发者ID:blackskaarj,项目名称:webgr,代码行数:14,代码来源:KeyTableSelect.php

示例11: __construct

 public function __construct($attributId, $spec = '', $options = '')
 {
     parent::__construct($spec, $options);
     $table = new ValueList();
     $select = $table->select();
     $select->order(ValueList::COL_NAME);
     $select->where(ValueList::COL_ATTRIBUTE_DESCRIPTOR_ID . "= ?", $attributId);
     $rowset = $table->fetchAll($select);
     $array = $rowset->toArray();
     $optArray = array(null => 'Please select');
     foreach ($array as $value) {
         $optArray = $optArray + array($value[ValueList::COL_ID] => $value[ValueList::COL_NAME]);
     }
     $this->setMultiOptions($optArray);
 }
开发者ID:blackskaarj,项目名称:webgr,代码行数:15,代码来源:ValuelistSelect.php

示例12: ReflectionClass

 function __construct($spec, $options = null)
 {
     parent::__construct($spec, $options);
     if (!isset($options['enum'])) {
         throw new Zend_Form_Exception('Please specify the enum type');
     }
     if (!class_exists($options['enum'])) {
         throw new Zend_Form_Exception('Enum type does not exists');
     }
     $enumName = $options['enum'];
     $oClass = new ReflectionClass($enumName);
     $constants = $oClass->getConstants();
     foreach ($constants as $constName => $constValue) {
         $this->addMultiOption($constValue, "{$enumName}::{$constName}");
     }
 }
开发者ID:DBezemer,项目名称:server,代码行数:16,代码来源:EnumSelect.php

示例13: __construct

 public function __construct($spec = '', $options = '', $group = '')
 {
     parent::__construct($spec, $options);
     $table = new AttributeDescriptor();
     $select = $table->select();
     $select->order(AttributeDescriptor::COL_NAME);
     if ($group != '') {
         $select->where(AttributeDescriptor::COL_GROUP . "= ?", $group);
     }
     $rowset = $table->fetchAll($select);
     $array = $rowset->toArray();
     $optArray = array(null => 'Please select');
     foreach ($array as $value) {
         $optArray = $optArray + array($value[AttributeDescriptor::COL_ID] => $value[AttributeDescriptor::COL_NAME]);
     }
     $this->setMultiOptions($optArray);
 }
开发者ID:blackskaarj,项目名称:webgr,代码行数:17,代码来源:AttributeSelect.php

示例14: __construct

 public function __construct($spec = '', $options = '')
 {
     parent::__construct($spec, $options);
     //		$table = new Expertise();
     //		$select = $table->select();
     //		$select->order(Expertise::COL_SPECIES);
     //		//$select->where(ValueList::COL_ATTRIBUTE_DESCRIPTOR_ID . "= ?",$attributId);
     //		$rowset = $table->fetchAll($select);
     $dbAdapter = Zend_Registry::get('DB_CONNECTION1');
     $select = $dbAdapter->select();
     $select->from(Expertise::TABLE_NAME);
     $select->joinLeft(array('valSpec' => ValueList::TABLE_NAME), Expertise::COL_SPECIES . ' = ' . 'valSpec.' . ValueList::COL_ID, array('valSpec' => ValueList::COL_VALUE));
     $select->joinLeft(array('valSubj' => ValueList::TABLE_NAME), Expertise::COL_SUBJECT . ' = ' . 'valSubj.' . ValueList::COL_ID, array('valSubj' => ValueList::COL_VALUE));
     $array = $dbAdapter->fetchAll($select);
     //$array = $rowset->toArray();
     $optArray = array(null => 'Please select');
     foreach ($array as $value) {
         $merged = $value[Expertise::COL_ID] . ',' . $value[Expertise::COL_AREA] . ',' . $value['valSpec'] . ',' . $value['valSubj'];
         $optArray = $optArray + array($value[Expertise::COL_ID] => $merged);
     }
     $this->setMultiOptions($optArray);
 }
开发者ID:blackskaarj,项目名称:webgr,代码行数:22,代码来源:ExpertiseSelect.php

示例15: __construct

 public function __construct($spec, $options = null)
 {
     $options = array_merge($options, $this->_defaultOptions);
     return parent::__construct($spec, $options);
 }
开发者ID:rom1git,项目名称:Centurion,代码行数:5,代码来源:OnOff.php


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