Пример #1
0
 /**
  * Constructor
  * Configures collection
  *
  * @return void
  */
 protected function _construct()
 {
     parent::_construct();
     $this->_init('Magento\\Newsletter\\Model\\Subscriber', 'Magento\\Newsletter\\Model\\Resource\\Subscriber');
     $this->_queueLinkTable = $this->getTable('newsletter_queue_link');
     $this->_storeTable = $this->getTable('store');
     $this->_map['fields']['type'] = $this->getResource()->getReadConnection()->getCheckSql('main_table.customer_id = 0', 1, 2);
     $this->_map['fields']['website_id'] = 'store.website_id';
     $this->_map['fields']['group_id'] = 'store.group_id';
     $this->_map['fields']['store_id'] = 'main_table.store_id';
 }
Пример #2
0
 /**
  * Constructor
  * Configures collection
  *
  * @return void
  */
 protected function _construct()
 {
     parent::_construct();
     $this->_init('Magento\\Newsletter\\Model\\Subscriber', 'Magento\\Newsletter\\Model\\Resource\\Subscriber');
     $this->_queueLinkTable = $this->getTable('newsletter_queue_link');
     $this->_storeTable = $this->getTable('store');
     // defining mapping for fields represented in several tables
     $this->_map['fields']['customer_lastname'] = 'customer_lastname_table.value';
     $this->_map['fields']['customer_firstname'] = 'customer_firstname_table.value';
     $this->_map['fields']['type'] = $this->getResource()->getReadConnection()->getCheckSql('main_table.customer_id = 0', 1, 2);
     $this->_map['fields']['website_id'] = 'store.website_id';
     $this->_map['fields']['group_id'] = 'store.group_id';
     $this->_map['fields']['store_id'] = 'main_table.store_id';
 }
Пример #3
0
 /**
  * Initialize collection items factory class
  *
  * @return void
  */
 protected function _construct()
 {
     $this->_init('Magento\\Paypal\\Model\\Payment\\Transaction', 'Magento\\Paypal\\Model\\Resource\\Payment\\Transaction');
     parent::_construct();
 }
Пример #4
0
 /**
  * @return void
  */
 protected function _construct()
 {
     parent::_construct();
     $this->_init('Magento\\CatalogRule\\Model\\Rule\\Product\\Price', 'Magento\\CatalogRule\\Model\\Resource\\Rule\\Product\\Price');
 }
Пример #5
0
 /**
  * Define resource model
  *
  * @return void
  */
 protected function _construct()
 {
     parent::_construct();
     $this->_init('Magento\\Core\\Model\\Layout\\Update', 'Magento\\Core\\Model\\Resource\\Layout\\Update');
 }
Пример #6
0
 /**
  * Define resource model
  *
  * @return void
  */
 protected function _construct()
 {
     parent::_construct();
     $this->_init('Magento\\Widget\\Model\\Layout\\Link', 'Magento\\Widget\\Model\\Resource\\Layout\\Link');
 }
Пример #7
0
 /**
  *  Define resource model
  *
  * @return void
  */
 protected function _construct()
 {
     parent::_construct();
     $this->_init('Magento\\Core\\Model\\Variable', 'Magento\\Core\\Model\\Resource\\Variable');
 }
Пример #8
0
 /**
  * Collection constructor
  *
  * @return void
  */
 protected function _construct()
 {
     parent::_construct();
     $this->_init('Magento\\SalesRule\\Model\\Rule\\Customer', 'Magento\\SalesRule\\Model\\Resource\\Rule\\Customer');
 }
 /**
  *  Define resource model
  *
  * @return void
  */
 protected function _construct()
 {
     parent::_construct();
     $this->_init('SweetTooth\\Webhook\\Model\\Webhook', 'SweetTooth\\Webhook\\Model\\Resource\\Webhook');
 }
Пример #10
0
 /**
  * Constructor
  *
  * @return void
  */
 protected function _construct()
 {
     parent::_construct();
     $this->_init('Magento\\Widget\\Model\\Widget\\Instance', 'Magento\\Widget\\Model\\Resource\\Widget\\Instance');
 }