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


PHP Varien_Data_Collection::__construct方法代码示例

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


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

示例1: __construct

 public function __construct($conn = null)
 {
     parent::__construct();
     if (!is_null($conn)) {
         $this->setConnection($conn);
     }
 }
开发者ID:vijays91,项目名称:Magento-My-Order-Search,代码行数:7,代码来源:Db.php

示例2: __construct

 /**
  * Initialize data to be loaded afterwards
  *
  * @param array $data
  * @return Varien_Data_Collection
  */
 public function __construct(array $data)
 {
     $data = current($data);
     if (empty($data)) {
         return parent::__construct();
     }
     $this->_toload = $data;
     return parent::__construct();
 }
开发者ID:CEMD-CN,项目名称:magemonkey,代码行数:15,代码来源:Customcollection.php

示例3: __construct

 /**
  * Collection constructor
  *
  * @param Mage_Core_Model_Mysql4_Abstract $resource
  */
 public function __construct($resource = null)
 {
     Mage::getSingleton('pap/config')->RequirePapAPI();
     parent::__construct();
     $this->_construct();
     $this->_resource = $resource;
     // create an API object for communication
     $this->_grid = $this->getResource()->createGridObject();
 }
开发者ID:AmineCherrai,项目名称:rostanvo,代码行数:14,代码来源:Abstract.php

示例4: __construct

 /**
  * Constructor
  *
  * @param   string $path - path to directory
  * @param   bool $is_recursion - use or not recursion
  * @return  none
  */
 public function __construct($path, $isRecursion = true, $recursionLevel = 0)
 {
     parent::__construct();
     $this->setPath($path);
     $this->_dirName = $this->lastDir();
     $this->setRecursion($isRecursion);
     $this->setRecursionLevel($recursionLevel);
     if ($this->getRecursion() || $this->getRecursionLevel() == 0) {
         $this->parseDir();
     }
 }
开发者ID:natxetee,项目名称:magento2,代码行数:18,代码来源:Collection.php

示例5: __construct

 public function __construct()
 {
     $apikey = Mage::helper('mailchimp')->getApiKey();
     $url = "http://" . substr($apikey, -3) . ".sts.mailchimp.com/1.0/ListVerifiedEmailAddresses";
     $params = array('apikey' => $apikey);
     $ch = curl_init();
     curl_setopt($ch, CURLOPT_URL, $url . '?' . http_build_query($params));
     curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
     $result = curl_exec($ch);
     curl_close($ch);
     $data = json_decode($result);
     if (isset($data->http_code)) {
         Mage::getSingleton('adminhtml/session')->addError(Mage::helper('mailchimp')->__('Mailchimp General Error: ') . $data->message);
     }
     if (isset($data->email_addresses)) {
         $this->_emailCollection = $data->email_addresses;
     }
     return parent::__construct();
 }
开发者ID:votanlean,项目名称:Magento-Pruebas,代码行数:19,代码来源:Sts.php

示例6: __construct

 public function __construct()
 {
     $apikey = Mage::helper('mailchimp')->getApiKey();
     $url = "http://" . substr($apikey, -3) . ".sts.mailchimp.com/1.0/ListVerifiedEmailAddresses";
     $params = array('apikey' => $apikey);
     $ch = curl_init();
     curl_setopt($ch, CURLOPT_URL, $url . '?' . http_build_query($params));
     curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
     $result = curl_exec($ch);
     curl_close($ch);
     $data = json_decode($result);
     //result must be in the following format
     //Array ( [Addresses] => Array ( [0] => rodrigod@ebizmarts.com [1] => info@ampcity.co.uk ) [RequestId] => c951b2a4-7cc9-11e0-95a7-35c0647356dc )
     if (isset($data->http_code)) {
         Mage::getSingleton('core/session')->addError('STS integration not set on mailchimp');
     }
     if (isset($data->email_addresses)) {
         $this->_emailCollection = $data->email_addresses;
     }
     return parent::__construct();
 }
开发者ID:votanlean,项目名称:Magento-Pruebas,代码行数:21,代码来源:Collection.php

示例7: __construct

 public function __construct($xml)
 {
     if (!is_object($xml) || (string) $xml->errorcode != '0000') {
         return parent::__construct();
     }
     if ((int) $xml->transactions->totalrows >= 1) {
         $cols = Mage::helper('sagepayreporting')->getDetailTransactionColumns();
         foreach ($xml->transactions->children() as $trn) {
             $rn = (string) $trn->rownumber;
             if (empty($rn)) {
                 continue;
             }
             $new = array('id' => $rn);
             foreach ($cols as $k => $v) {
                 $new[$k] = (string) $trn->{$k};
             }
             $this->_relatedTransactions[] = $new;
         }
     }
     return parent::__construct();
 }
开发者ID:MadMaxAi,项目名称:sage-pay-suite-ce,代码行数:21,代码来源:Collection.php

示例8: __construct

 /**
  * Constructor
  *
  * Sets default item object class and default sort order.
  */
 public function __construct()
 {
     parent::__construct();
     $this->setItemObjectClass(AO::getConfig()->getModelClassName('backup/backup'))->setOrder('time', 'desc');
 }
开发者ID:ronseigel,项目名称:agent-ohm,代码行数:10,代码来源:Fs_Collection.php

示例9: __construct

 public function __construct()
 {
     parent::__construct();
     $this->setItemObjectClass('mzax_emarketing/campaign_preset');
 }
开发者ID:sakibanda,项目名称:emarketing,代码行数:5,代码来源:Collection.php

示例10: __construct

 public function __construct($conn = null)
 {
     parent::__construct();
     $this->_select = new DMC_Solr_Model_SolrServer_Select();
 }
开发者ID:georgebabarus,项目名称:Magento-Solr,代码行数:5,代码来源:AbstractCollection.php

示例11: __construct

 public function __construct()
 {
     parent::__construct();
     $this->_api = Mage::getSingleton('eltrino_diamantedesk/api');
 }
开发者ID:eltrino,项目名称:DiamanteDeskMagentoExtension,代码行数:5,代码来源:Collection.php


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