コード例 #1
0
ファイル: Applicant.php プロジェクト: eugenzor/zfhrtool
 /**
  * Constructor.
  *
  * @param  int $applicantId optional
  * @return void
  */
 public function __construct(array $config = array(), $applicantId = null)
 {
     parent::__construct($config);
     if ($applicantId) {
         $this->id = $applicantId;
     }
 }
コード例 #2
0
ファイル: Answer.php プロジェクト: eugenzor/zfhrtool
 /**
  * Constructor.
  *
  * @param  int $id optional
  * @return void
  */
 public function __construct(array $config = array(), $id = null)
 {
     parent::__construct($config);
     if ($id) {
         $this->tqa_id = $id;
     }
 }
コード例 #3
0
ファイル: Test.php プロジェクト: eugenzor/zfhrtool
 /**
  * Constructor.
  *
  * @param  int $testId optional
  * @return void
  */
 public function __construct(array $config = array(), $testId = null)
 {
     parent::__construct($config);
     if ($testId) {
         $this->t_id = $testId;
     }
 }
コード例 #4
0
ファイル: Abstract.php プロジェクト: BackupTheBerlios/zfblank
 /** \zfb_read ActiveRow_Abstract..__construct */
 public function __construct(array $config = array())
 {
     if ($this->_finishDataMap || isset($config['finishDataMap'])) {
         if (isset($config['table']) && $config['table'] instanceof Zend_Db_Table_Abstract) {
             $table = $config['table'];
         } elseif ($this->_tableClass !== null) {
             $table = $this->_getTableFromString($this->_tableClass);
         } else {
             //table is undefined: not completing dataMap
             parent::__construct($config);
             return;
         }
         $cols = $table->info('cols');
         $result = array();
         foreach ($cols as $colName) {
             if (($key = array_search($colName, $this->_dataMap)) !== FALSE) {
                 $result[$key] = $colName;
             } else {
                 $result[$this->_dataMapTransform($colName)] = $colName;
             }
         }
         $this->_dataMap = $result;
     }
     parent::__construct($config);
 }
コード例 #5
0
 public function __construct($config = array())
 {
     if (array_key_exists('data', $config)) {
         $config['data']['id'] = (int) $config['data']['id'];
         $config['data']['randomNumber'] = (int) $config['data']['randomNumber'];
     }
     parent::__construct($config);
 }
コード例 #6
0
ファイル: Row.php プロジェクト: bklein01/SiberianCMS
 public function __construct(array $options = array())
 {
     parent::__construct($options);
     try {
         $this->_cols = $this->getTable()->info('cols');
         foreach ($this->_cols as $col) {
             if (!isset($this->_data[$col])) {
                 $this->_data[$col] = null;
             }
         }
     } catch (Exception $e) {
     }
 }
コード例 #7
0
 public function __construct(array $config)
 {
     // @todo Technically, we should have this run after serialization because
     // init will get called before unserialization
     parent::__construct($config);
     // Unserialize rows
     if ($this->_table instanceof Engine_Db_Table && null !== ($cols = $this->_table->getSerializedColumns())) {
         foreach ($cols as $colName) {
             if (!empty($this->_data[$colName]) && is_scalar($this->_data[$colName]) && false != ($val = Zend_Json::decode($this->_data[$colName])) && $val != $this->_data[$colName]) {
                 $this->_data[$colName] = $val;
             }
         }
     }
 }
コード例 #8
0
ファイル: Row.php プロジェクト: ngukho/ducbui-cms
 public function __construct($config = array())
 {
     parent::__construct($config);
     $this->cache = new Digitalus_Db_Cache($this);
 }
コード例 #9
0
ファイル: Abstract.php プロジェクト: uglide/zfcore-transition
 /**
  * Constructor
  * @param array $config array $config OPTIONAL Array of user-specified config options.
  * @param string $suffix
  * @return \Core_Db_Table_Row_Abstract
  */
 public function __construct(array $config = array(), $suffix = '_Table')
 {
     $this->_tableClass = get_class($this) . $suffix;
     parent::__construct($config);
 }
コード例 #10
0
ファイル: Abstract.php プロジェクト: netconstructor/Centurion
 public function __construct(array $config)
 {
     parent::__construct($config);
     Centurion_Traits_Common::initTraits($this);
 }
コード例 #11
0
ファイル: Row.php プロジェクト: dmelo/dzend
 public function __construct($config = array())
 {
     parent::__construct($config);
     $this->_enableTransform = true;
     $this->_logger = Zend_Registry::get('logger');
 }
コード例 #12
0
ファイル: Abstract.php プロジェクト: pansot2/PadCMS-backend
 /**
  * @param array $aConfig
  */
 public function __construct(array $aConfig = array())
 {
     $this->_tableClass = $this->_getTableClass();
     parent::__construct($aConfig);
 }
コード例 #13
0
 public function __construct(array $config = array())
 {
     parent::__construct($config);
     $this->fetchIngredient();
     $this->fetchMeasurement();
 }
コード例 #14
0
ファイル: Abstract.php プロジェクト: shahmaulik/zfcore
 /**
  * Constructor
  *
  * @param  array $config OPTIONAL Array of user-specified config options.
  * @return \Core_Db_Table_Row_Abstract
  */
 public function __construct(array $config = array())
 {
     $this->_tableClass = get_class($this) . '_Table';
     parent::__construct($config);
 }