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


PHP Tinebase_Backend_Sql_Abstract::__construct方法代码示例

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


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

示例1: __construct

 /**
  * the constructor
  * 
  * @param Zend_Db_Adapter_Abstract $_db (optional)
  * @param array $_options (optional)
  */
 public function __construct($_dbAdapter = NULL, $_options = array())
 {
     parent::__construct($_dbAdapter, $_options);
     // set default adapter
     $config = Tinebase_Core::getConfig();
     $adapter = $config->{Tinebase_Auth_CredentialCache_Adapter_Config::CONFIG_KEY} ? 'Config' : 'Cookie';
     $this->setCacheAdapter($adapter);
 }
开发者ID:rodrigofns,项目名称:ExpressoLivre3,代码行数:14,代码来源:CredentialCache.php

示例2: __construct

 /**
  * the constructor
  *
  * allowed options:
  *  - modelName
  *  - tableName
  *  - tablePrefix
  *  - modlogActive
  *
  * @param Zend_Db_Adapter_Abstract $_db (optional)
  * @param array $_options (optional)
  * @throws Tinebase_Exception_Backend_Database
  */
 public function __construct($_dbAdapter = NULL, $_options = array())
 {
     parent::__construct($_dbAdapter, $_options);
     $this->_additionalSearchCountCols = array('is_billable_combined' => null, 'duration' => 'duration', 'duration_billable' => null);
     $this->_foreignTables['is_billable_combined']['select'] = array('is_billable_combined' => new Zend_Db_Expr('(' . $this->_db->quoteIdentifier('timetracker_timesheet.is_billable') . '*' . $this->_db->quoteIdentifier('timetracker_timeaccount.is_billable') . ')'));
     $this->_foreignTables['is_cleared_combined']['select'] = array('is_cleared_combined' => new Zend_Db_Expr('(CASE WHEN ' . $this->_db->quoteIdentifier('timetracker_timesheet.is_cleared') . " = '1' OR " . $this->_db->quoteIdentifier('timetracker_timeaccount.status') . " = 'billed' THEN 1 ELSE 0 END)"));
     $this->_foreignTables['duration_billable']['select'] = array('duration_billable' => new Zend_Db_Expr('(' . $this->_db->quoteIdentifier('duration') . '*' . $this->_db->quoteIdentifier('timetracker_timesheet.is_billable') . '*' . $this->_db->quoteIdentifier('timetracker_timeaccount.is_billable') . ')'));
 }
开发者ID:ingoratsdorf,项目名称:Tine-2.0-Open-Source-Groupware-and-CRM,代码行数:21,代码来源:Timesheet.php

示例3: __construct

 /**
  * the constructor
  * 
  * allowed options:
  *  - modelName
  *  - tableName
  *  - tablePrefix
  *  - modlogActive
  *  
  * @param Zend_Db_Adapter_Abstract $_dbAdapter (optional)
  * @param array $_options (optional)
  * @throws Tinebase_Exception_Backend_Database
  */
 public function __construct($_dbAdapter = NULL, $_options = array())
 {
     parent::__construct($_dbAdapter, $_options);
     /**
      * TODO move this code somewhere and make it optionally. Maybe even make it a new controller / frontend action and request the data async
      */
     if (Addressbook_Config::getInstance()->featureEnabled(Addressbook_Config::FEATURE_LIST_VIEW)) {
         $this->_additionalColumns['emails'] = new Zend_Db_Expr('(' . $this->_db->select()->from($this->_tablePrefix . 'addressbook', array($this->_dbCommand->getAggregate('email')))->where($this->_db->quoteIdentifier('id') . ' IN ?', $this->_db->select()->from(array('addressbook_list_members' => $this->_tablePrefix . 'addressbook_list_members'), array('contact_id'))->where($this->_db->quoteIdentifier('addressbook_list_members.list_id') . ' = ' . $this->_db->quoteIdentifier('addressbook_lists.id'))) . ')');
     }
 }
开发者ID:ingoratsdorf,项目名称:Tine-2.0-Open-Source-Groupware-and-CRM,代码行数:23,代码来源:List.php

示例4: __construct

 /**
  * the constructor
  *
  * allowed numberableConfiguration:
  *  - tablename (req)
  *  - numberablecolumn (req)
  *  - stepsize (optional)
  *  - bucketcolumn (optional)
  *  - bucketkey (optional)
  *
  *
  * allowed options:
  * see parent class
  *
  * @param array $_numberableConfiguration
  * @param Zend_Db_Adapter_Abstract $_db (optional)
  * @param array $_options (optional)
  * @throws Tinebase_Exception_Backend_Database
  */
 public function __construct($_numberableConfiguration, $_dbAdapter = NULL, $_options = array())
 {
     if (!isset($_numberableConfiguration[Tinebase_Numberable_Abstract::CONF_TABLENAME])) {
         throw new Tinebase_Exception_UnexpectedValue(__CLASS__ . ' is missing "' . Tinebase_Numberable_Abstract::CONF_TABLENAME . '" configuration.');
     }
     $this->_tableName = $_numberableConfiguration[Tinebase_Numberable_Abstract::CONF_TABLENAME];
     if (!isset($_numberableConfiguration[Tinebase_Numberable_Abstract::CONF_NUMCOLUMN])) {
         throw new Tinebase_Exception_UnexpectedValue(__CLASS__ . ' is missing "' . Tinebase_Numberable_Abstract::CONF_NUMCOLUMN . '" configuration.');
     }
     $this->_numberableColumn = $_numberableConfiguration[Tinebase_Numberable_Abstract::CONF_NUMCOLUMN];
     parent::__construct($_dbAdapter, $_options);
     if (isset($_numberableConfiguration[Tinebase_Numberable_Abstract::CONF_STEPSIZE])) {
         if (!is_int($_numberableConfiguration[Tinebase_Numberable_Abstract::CONF_STEPSIZE])) {
             throw new Tinebase_Exception_UnexpectedValue(__CLASS__ . ' found improper "' . Tinebase_Numberable_Abstract::CONF_STEPSIZE . '" configuration: (not a int) "' . $_numberableConfiguration[Tinebase_Numberable_Abstract::CONF_STEPSIZE] . '"');
         }
         $this->_stepSize = intval($_numberableConfiguration[Tinebase_Numberable_Abstract::CONF_STEPSIZE]);
     }
     if (isset($_numberableConfiguration[Tinebase_Numberable_Abstract::CONF_BUCKETCOLUMN])) {
         $this->_bucketColumn = $_numberableConfiguration[Tinebase_Numberable_Abstract::CONF_BUCKETCOLUMN];
     }
     if (isset($_numberableConfiguration[Tinebase_Numberable_Abstract::CONF_BUCKETKEY])) {
         $this->_bucketKey = $_numberableConfiguration[Tinebase_Numberable_Abstract::CONF_BUCKETKEY];
     }
 }
开发者ID:ingoratsdorf,项目名称:Tine-2.0-Open-Source-Groupware-and-CRM,代码行数:43,代码来源:Abstract.php

示例5: __construct

 /**
  * (non-PHPdoc)
  * @see Tinebase_Backend_Sql_Abstract::__construct()
  */
 public function __construct($_dbAdapter = NULL, $_options = array())
 {
     parent::__construct($_dbAdapter, $_options);
     $this->_foreignTables['jpegphoto']['select'] = array('jpegphoto' => $this->_dbCommand->getIfIsNull('addressbook_image.contact_id', 0, 1));
 }
开发者ID:bitExpert,项目名称:Tine-2.0-Open-Source-Groupware-and-CRM,代码行数:9,代码来源:Sql.php

示例6: __construct

 public function __construct($_dbAdapter = null, array $_options = array())
 {
     parent::__construct($_dbAdapter, $_options);
     $this->_foreignTables['jpegphoto']['select'] = array('jpegphoto' => Tinebase_Backend_Sql_Command::getIfIsNull($this->_db, $this->_db->quoteIdentifier('addressbook_image.contact_id'), 0, 1));
 }
开发者ID:rodrigofns,项目名称:ExpressoLivre3,代码行数:5,代码来源:Sql.php

示例7: __construct

 /**
  * the constructor
  *
  * @param Zend_Db_Adapter_Abstract $_db optional
  * @param array $_options (optional)
  */
 public function __construct($_dbAdapter = NULL, $_options = array())
 {
     parent::__construct($_dbAdapter, $_options);
     $this->_attendeeBackend = new Calendar_Backend_Sql_Attendee($_dbAdapter);
 }
开发者ID:ingoratsdorf,项目名称:Tine-2.0-Open-Source-Groupware-and-CRM,代码行数:11,代码来源:Sql.php

示例8: __construct

 public function __construct($_dbAdapter = NULL, $_modelName = NULL, $_tableName = NULL, $_tablePrefix = NULL, $_modlogActive = NULL, $_useSubselectForCount = NULL)
 {
     parent::__construct($_dbAdapter, $_modelName, $_tableName, $_tablePrefix, $_modlogActive, $_useSubselectForCount);
     $this->opBackend = new Billing_Backend_OrderPosition();
 }
开发者ID:carriercomm,项目名称:Billing-5,代码行数:5,代码来源:ArticleSold.php

示例9: __construct

 /**
  * the constructor
  * 
  * allowed options:
  *  - modelName
  *  - tableName
  *  - tablePrefix
  *  - modlogActive
  *  
  * @param Zend_Db_Adapter_Abstract $_db (optional)
  * @param array $_options (optional)
  * @throws Tinebase_Exception_Backend_Database
  */
 public function __construct($_dbAdapter = NULL, $_options = array())
 {
     parent::__construct($_dbAdapter, $_options);
     $this->_additionalColumns['emails'] = new Zend_Db_Expr('(' . $this->_db->select()->from($this->_tablePrefix . 'addressbook', array($this->_dbCommand->getAggregate('email')))->where($this->_db->quoteIdentifier('id') . ' IN ?', $this->_db->select()->from(array('addressbook_list_members' => $this->_tablePrefix . 'addressbook_list_members'), array('contact_id'))->where($this->_db->quoteIdentifier('addressbook_list_members.list_id') . ' = ' . $this->_db->quoteIdentifier('addressbook_lists.id'))) . ')');
 }
开发者ID:hernot,项目名称:Tine-2.0-Open-Source-Groupware-and-CRM,代码行数:18,代码来源:List.php

示例10: __construct

 /**
  * (non-PHPdoc)
  * @see Tinebase_Backend_Sql_Abstract::__construct()
  */
 public function __construct($_dbAdapter = NULL, $_options = array())
 {
     parent::__construct($_dbAdapter, $_options);
 }
开发者ID:ingoratsdorf,项目名称:Tine-2.0-Open-Source-Groupware-and-CRM,代码行数:8,代码来源:Scheduler.php


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