本文整理汇总了PHP中Ess_M2ePro_Model_Marketplace类的典型用法代码示例。如果您正苦于以下问题:PHP Ess_M2ePro_Model_Marketplace类的具体用法?PHP Ess_M2ePro_Model_Marketplace怎么用?PHP Ess_M2ePro_Model_Marketplace使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了Ess_M2ePro_Model_Marketplace类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: logSuccessfulOperation
protected function logSuccessfulOperation(Ess_M2ePro_Model_Marketplace $marketplace)
{
// M2ePro_TRANSLATIONS
// The "Categories" action for Rakuten Marketplace: "%mrk%" has been successfully completed.
$tempString = Mage::getModel('M2ePro/Log_Abstract')->encodeDescription('The "Categories" action for Rakuten Marketplace: "%mrk%" has been successfully completed.', array('mrk' => $marketplace->getTitle()));
$this->getLog()->addMessage($tempString, Ess_M2ePro_Model_Log_Abstract::TYPE_SUCCESS, Ess_M2ePro_Model_Log_Abstract::PRIORITY_LOW);
}
开发者ID:ashfaqphplhr,项目名称:artificiallawnsforturf,代码行数:7,代码来源:Categories.php
示例2: logSuccessfulOperation
protected function logSuccessfulOperation(Ess_M2ePro_Model_Marketplace $marketplace)
{
// M2ePro_TRANSLATIONS
// The "Details" Action for %amazon% Marketplace: "%mrk%" has been successfully completed.
$tempString = Mage::getModel('M2ePro/Log_Abstract')->encodeDescription('The "Details" Action for %amazon% Marketplace: "%mrk%" has been successfully completed.', array('!amazon' => Mage::helper('M2ePro/Component_Amazon')->getTitle(), 'mrk' => $marketplace->getTitle()));
$this->getLog()->addMessage($tempString, Ess_M2ePro_Model_Log_Abstract::TYPE_SUCCESS, Ess_M2ePro_Model_Log_Abstract::PRIORITY_LOW);
}
开发者ID:newedge-media,项目名称:iwantmymeds,代码行数:7,代码来源:Details.php
示例3: parseShippingAddress
private function parseShippingAddress(array $shippingData, Ess_M2ePro_Model_Marketplace $marketplace)
{
$location = isset($shippingData['location']) ? $shippingData['location'] : array();
$address = isset($shippingData['address']) ? $shippingData['address'] : array();
$parsedAddress = array('county' => isset($location['county']) ? trim($location['county']) : '', 'country_code' => isset($location['country_code']) ? trim($location['country_code']) : '', 'state' => isset($location['state']) ? trim($location['state']) : '', 'city' => isset($location['city']) ? trim($location['city']) : '', 'postal_code' => isset($location['postal_code']) ? $location['postal_code'] : '', 'recipient_name' => isset($shippingData['buyer']) ? trim($shippingData['buyer']) : '', 'phone' => isset($shippingData['phone']) ? $shippingData['phone'] : '', 'company' => '', 'street' => array(isset($address['first']) ? $address['first'] : '', isset($address['second']) ? $address['second'] : '', isset($address['third']) ? $address['third'] : ''));
$parsedAddress['street'] = array_filter($parsedAddress['street']);
$group = '/amazon/order/settings/marketplace_' . $marketplace->getId() . '/';
$useFirstStreetLineAsCompany = Mage::helper('M2ePro/Module')->getConfig()->getGroupValue($group, 'use_first_street_line_as_company');
if ($useFirstStreetLineAsCompany && count($parsedAddress['street']) > 1) {
$parsedAddress['company'] = array_shift($parsedAddress['street']);
}
return $parsedAddress;
}
开发者ID:xiaoguizhidao,项目名称:devfashion,代码行数:13,代码来源:ItemsResponser.php
示例4: addMotorsSpecificsData
protected function addMotorsSpecificsData(Ess_M2ePro_Model_Listing_Product $listingProduct, Ess_M2ePro_Model_Marketplace $marketplace, Ess_M2ePro_Model_Ebay_Template_Category $categoryTemplate, array &$requestData)
{
if ($marketplace->getId() != Ess_M2ePro_Helper_Component_Ebay::MARKETPLACE_MOTORS) {
return;
}
$categoryId = $categoryTemplate->getMainCategory();
$categoryData = $marketplace->getChildObject()->getCategory($categoryId);
$features = !empty($categoryData['features']) ? (array) json_decode($categoryData['features'], true) : array();
$attributes = !empty($features['parts_compatibility_attributes']) ? $features['parts_compatibility_attributes'] : array();
if (empty($attributes)) {
return;
}
$categoryTemplate->getMagentoProduct()->clearNotFoundAttributes();
$specifics = Mage::helper('M2ePro/Component_Ebay_MotorsSpecifics')->getSpecifics($listingProduct);
if ($specifics === false) {
return;
}
$notFoundAttributes = $categoryTemplate->getMagentoProduct()->getNotFoundAttributes();
if (!empty($notFoundAttributes)) {
Mage::getModel('M2ePro/Connector_Server_Ebay_Item_Helper')->addNotFoundAttributesMessage($listingProduct, Mage::helper('M2ePro')->__('Compatibility'), $notFoundAttributes);
return;
}
$requestData['motors_specifics'] = array();
foreach ($specifics as $specific) {
$compatibilityList = array();
$compatibilityData = $specific->getCompatibilityData();
foreach ($compatibilityData as $key => $value) {
if ($value == '--') {
unset($compatibilityData[$key]);
continue;
}
$name = $key;
foreach ($attributes as $attribute) {
if ($attribute['title'] == $key) {
$name = $attribute['ebay_id'];
break;
}
}
$compatibilityList[] = array('name' => $name, 'value' => $value);
}
$requestData['motors_specifics'][] = $compatibilityList;
}
}
开发者ID:xiaoguizhidao,项目名称:bb,代码行数:43,代码来源:HelperCategory.php
示例5: processAccountMarketplace
private function processAccountMarketplace(Ess_M2ePro_Model_Account $account, Ess_M2ePro_Model_Marketplace $marketplace)
{
$title = 'Starting account "%s" and marketplace "%s"';
$title = sprintf($title, $account->getTitle(), $marketplace->getTitle());
$this->_profiler->addTitle($title);
$this->_profiler->addTimePoint(__METHOD__ . 'send' . $account->getId(), 'Update orders on Rakuten.com');
$status = 'Task "%s" for Rakuten.com "%s" Account and "%s" marketplace is started. Please wait...';
$status = Mage::helper('M2ePro')->__($status, $this->name, $account->getTitle(), $marketplace->getTitle());
$this->_lockItem->setStatus($status);
$changesCollection = Mage::getModel('M2ePro/Order_Change')->getCollection();
$changesCollection->addAccountFilter($account->getId());
$changesCollection->addProcessingAttemptDateFilter();
$changesCollection->addFieldToFilter('component', Ess_M2ePro_Helper_Component_Buy::NICK);
$changesCollection->addFieldToFilter('action', Ess_M2ePro_Model_Order_Change::ACTION_UPDATE_SHIPPING);
$changesCollection->getSelect()->group(array('order_id'));
if ($changesCollection->getSize() == 0) {
return;
}
// Update orders shipping status on Rakuten.com
//---------------------------
$params = array();
foreach ($changesCollection as $change) {
$changeParams = $change->getParams();
$params[] = array('change_id' => $change->getId(), 'order_id' => $change->getOrderId(), 'buy_order_id' => $changeParams['buy_order_id'], 'buy_order_item_id' => $changeParams['buy_order_item_id'], 'qty' => $changeParams['qty'], 'tracking_type' => $changeParams['tracking_type'], 'tracking_number' => $changeParams['tracking_number'], 'ship_date' => $changeParams['ship_date']);
}
if (count($params) == 0) {
return;
}
Mage::getResourceModel('M2ePro/Order_Change')->incrementAttemptCount($changesCollection->getAllIds());
$entity = 'orders';
$type = 'update';
$name = 'shipping';
/** @var $dispatcherObject Ess_M2ePro_Model_Connector_Server_Buy_Dispatcher */
$dispatcherObject = Mage::getModel('M2ePro/Connector_Server_Buy_Dispatcher');
$dispatcherObject->processConnector($entity, $type, $name, $params, $marketplace, $account);
//---------------------------
$this->_profiler->saveTimePoint(__METHOD__ . 'send' . $account->getId());
$this->_profiler->addEol();
}
开发者ID:xiaoguizhidao,项目名称:bb,代码行数:39,代码来源:Update.php
示例6: updateAccountMarketplace
private function updateAccountMarketplace(Ess_M2ePro_Model_Account $accountObj, Ess_M2ePro_Model_Marketplace $marketplaceObj)
{
$this->_profiler->addTitle('Starting account "' . $accountObj->getTitle() . '" and marketplace "' . $marketplaceObj->getTitle() . '"');
$this->_profiler->addTimePoint(__METHOD__ . 'send' . $accountObj->getId(), 'Get inventory from Amazon');
$tempString = 'Task "3rd Party Listings Synchronization" for Amazon account: ';
$tempString .= '"%s" and marketplace "%s" is started. Please wait...';
$this->_lockItem->setStatus(Mage::helper('M2ePro')->__($tempString, $accountObj->getTitle(), $marketplaceObj->getTitle()));
// Get all changes on Amazon for account
//---------------------------
$dispatcherObject = Mage::getModel('M2ePro/Connector_Server_Amazon_Dispatcher');
$dispatcherObject->processConnector('tasks', 'otherListings', 'requester', array(), $marketplaceObj, $accountObj, 'Ess_M2ePro_Model_Amazon_Synchronization');
//---------------------------
$this->_profiler->saveTimePoint(__METHOD__ . 'send' . $accountObj->getId());
$this->_profiler->addEol();
}
开发者ID:xiaoguizhidao,项目名称:bb,代码行数:15,代码来源:OtherListings.php
示例7: processAccountMarketplace
private function processAccountMarketplace(Ess_M2ePro_Model_Account $account, Ess_M2ePro_Model_Marketplace $marketplace)
{
$title = 'Starting account "%s" and marketplace "%s%';
$title = sprintf($title, $account->getTitle(), $marketplace->getTitle());
$this->_profiler->addTitle($title);
$this->_profiler->addTimePoint(__METHOD__ . 'send' . $account->getId(), 'Get orders from Play');
$status = 'Task "%s" for Play.com "%s" Account and "%s" marketplace is started. Please wait...';
$status = Mage::helper('M2ePro')->__($status, $this->name, $account->getTitle(), $marketplace->getTitle());
$this->_lockItem->setStatus($status);
//------------------------------
$fromDate = $this->prepareFromDate($account->getData('orders_last_synchronization'));
$params = array('from_date' => $fromDate);
if (is_null($account->getData('orders_last_synchronization'))) {
$account->setData('orders_last_synchronization', $fromDate)->save();
}
//------------------------------
// Get open orders from Play.com for account
//---------------------------
/** @var $dispatcherObject Ess_M2ePro_Model_Connector_Server_Play_Dispatcher */
$dispatcherObject = Mage::getModel('M2ePro/Connector_Server_Play_Dispatcher');
$prefix = 'Ess_M2ePro_Model_Play_Synchronization';
$dispatcherObject->processConnector('tasks', 'orders_receive', 'requester', $params, $marketplace, $account, $prefix);
//---------------------------
$this->_profiler->saveTimePoint(__METHOD__ . 'send' . $account->getId());
$this->_profiler->addEol();
}
开发者ID:xiaoguizhidao,项目名称:bb,代码行数:26,代码来源:Receive.php
示例8: processAccountMarketplace
private function processAccountMarketplace(Ess_M2ePro_Model_Account $account, Ess_M2ePro_Model_Marketplace $marketplace)
{
$title = 'Starting account "' . $account->getTitle() . '" and marketplace "' . $marketplace->getTitle() . '"';
$this->_profiler->addTitle($title);
$this->_profiler->addTimePoint(__METHOD__ . 'send' . $account->getId(), 'Update orders on Amazon');
$status = 'Task "%s" for Amazon "%s" Account and "%s" marketplace is started. Please wait...';
$status = Mage::helper('M2ePro')->__($status, $this->name, $account->getTitle(), $marketplace->getTitle());
$this->_lockItem->setStatus($status);
$changesCollection = Mage::getModel('M2ePro/Order_Change')->getCollection();
$changesCollection->addAccountFilter($account->getId());
$changesCollection->addProcessingAttemptDateFilter();
$changesCollection->addFieldToFilter('component', Ess_M2ePro_Helper_Component_Amazon::NICK);
$changesCollection->addFieldToFilter('action', Ess_M2ePro_Model_Order_Change::ACTION_UPDATE_SHIPPING);
$changesCollection->setPageSize(self::MAX_UPDATES_PER_TIME);
$changesCollection->getSelect()->group(array('order_id'));
if ($changesCollection->getSize() == 0) {
return;
}
// Update orders shipping status on Rakuten.com
//---------------------------
$items = array();
foreach ($changesCollection as $change) {
$changeParams = $change->getParams();
$items[] = array('order_id' => $change->getOrderId(), 'change_id' => $change->getId(), 'amazon_order_id' => $changeParams['amazon_order_id'], 'tracking_number' => $changeParams['tracking_number'], 'carrier_name' => $changeParams['carrier_name'], 'fulfillment_date' => $changeParams['fulfillment_date'], 'shipping_method' => isset($changeParams['shipping_method']) ? $changeParams['shipping_method'] : null, 'items' => $changeParams['items']);
}
if (count($items) == 0) {
return;
}
Mage::getResourceModel('M2ePro/Order_Change')->incrementAttemptCount($changesCollection->getAllIds());
/** @var $dispatcherObject Ess_M2ePro_Model_Connector_Server_Amazon_Dispatcher */
$dispatcherObject = Mage::getModel('M2ePro/Connector_Server_Amazon_Dispatcher');
$dispatcherObject->processConnector('orders', 'update', 'items', array('items' => $items), $marketplace, $account);
//---------------------------
$this->_profiler->saveTimePoint(__METHOD__ . 'send' . $account->getId());
$this->_profiler->addEol();
}
开发者ID:xiaoguizhidao,项目名称:bb,代码行数:36,代码来源:Update.php
示例9: updateAccountMarketplace
private function updateAccountMarketplace(Ess_M2ePro_Model_Account $accountObj, Ess_M2ePro_Model_Marketplace $marketplaceObj)
{
$this->_profiler->addTitle('Starting account "' . $accountObj->getTitle() . '" and marketplace "' . $marketplaceObj->getTitle() . '"');
$this->_profiler->addTimePoint(__METHOD__ . 'send' . $accountObj->getId(), 'Get orders from Amazon');
//->__('Task "Orders Synchronization" for Amazon account: "%s" and marketplace "%s" is started. Please wait...')
$tempString = 'Task "Orders Synchronization" for Amazon account: ';
$tempString .= '"%s" and marketplace "%s" is started. Please wait...';
$this->_lockItem->setStatus(Mage::helper('M2ePro')->__($tempString, $accountObj->getTitle(), $marketplaceObj->getTitle()));
// Get orders from Amazon for account
//---------------------------
$fromDate = $this->prepareFromDate($accountObj->getData('orders_last_synchronization'));
$params = array('from_date' => $fromDate);
if (is_null($accountObj->getData('orders_last_synchronization'))) {
$accountObj->setData('orders_last_synchronization', $fromDate)->save();
}
$dispatcherObject = Mage::getModel('M2ePro/Amazon_Connector')->getDispatcher();
$dispatcherObject->processConnector('tasks', 'orders', 'requester', $params, $marketplaceObj, $accountObj, 'Ess_M2ePro_Model_Amazon_Synchronization');
//---------------------------
$this->_profiler->saveTimePoint(__METHOD__ . 'send' . $accountObj->getId());
$this->_profiler->addEol();
}
开发者ID:xiaoguizhidao,项目名称:beut,代码行数:21,代码来源:Orders.php
示例10: receiveFromEbay
protected function receiveFromEbay(Ess_M2ePro_Model_Marketplace $marketplace, Ess_M2ePro_Model_Account $account)
{
$policies = Mage::getModel('M2ePro/Connector_Ebay_Dispatcher')->processVirtual('account', 'get', 'policies', array(), 'policies', $marketplace->getId(), $account->getId(), NULL);
is_null($policies) && ($policies = array());
$this->getActualOperationHistory()->addText('Total received policies from eBay: ' . count($policies));
return $policies;
}
开发者ID:ashfaqphplhr,项目名称:artificiallawnsforturf,代码行数:7,代码来源:Receive.php
示例11: processAccountMarketplaceInventoryTitle
private function processAccountMarketplaceInventoryTitle(Ess_M2ePro_Model_Account $accountObj, Ess_M2ePro_Model_Marketplace $marketplaceObj)
{
$firstSynchronizationTime = $accountObj->getChildObject()->getOtherListingsFirstSynchronization();
if (is_null($firstSynchronizationTime) || strtotime($firstSynchronizationTime) + 3 * 3600 > Mage::helper('M2ePro')->getCurrentGmtDate(true)) {
return;
}
$this->_profiler->addTitle('Starting account "' . $accountObj->getTitle() . '" and marketplace "' . $marketplaceObj->getTitle() . '"');
$this->_profiler->addTimePoint(__METHOD__ . 'send' . $accountObj->getId(), 'Get inventory from Buy');
$tempString = Mage::helper('M2ePro')->__('Task "3rd Party Listings Synchronization" for Rakuten.com account: ');
$tempString .= Mage::helper('M2ePro')->__('"%s" and marketplace "%s" is started. Please wait...', $accountObj->getTitle(), Mage::helper('M2ePro')->__($marketplaceObj->getTitle()));
$this->_lockItem->setStatus($tempString);
$updateByPagesSettings = $accountObj->getChildObject()->getDecodedOtherListingsUpdateTitlesSettings();
if (is_null($updateByPagesSettings) || (int) $updateByPagesSettings['next_status'] <= 2 && (int) $updateByPagesSettings['next_page'] < 10000) {
$this->updateInventoryTitlesByPages($accountObj, $marketplaceObj);
} else {
$this->updateInventoryTitlesBySkus($accountObj, $marketplaceObj);
}
$this->_profiler->saveTimePoint(__METHOD__ . 'send' . $accountObj->getId());
$this->_profiler->addEol();
}
开发者ID:xiaoguizhidao,项目名称:beut,代码行数:20,代码来源:OtherListings.php
示例12: updateAccountMarketplace
private function updateAccountMarketplace(Ess_M2ePro_Model_Account $account, Ess_M2ePro_Model_Marketplace $marketplace)
{
$this->_profiler->addTitle('Starting account "' . $account->getTitle() . '" and marketplace "' . $marketplace->getTitle() . '"');
$this->_profiler->addTimePoint(__METHOD__ . 'send' . $account->getId(), 'Get orders from Amazon');
//->__('Task "%s" for Amazon account: "%s" and marketplace "%s" is started. Please wait...')
$status = 'Task "%s" for Amazon account: "%s" and marketplace "%s" is started. Please wait...';
$status = Mage::helper('M2ePro')->__($status, $this->name, $account->getTitle(), $marketplace->getTitle());
$this->_lockItem->setStatus($status);
// Get orders from Amazon for account
//---------------------------
$fromDate = $this->prepareFromDate($account->getData('orders_last_synchronization'));
$params = array('from_date' => $fromDate);
if (is_null($account->getData('orders_last_synchronization'))) {
$account->setData('orders_last_synchronization', $fromDate)->save();
}
$entity = 'tasks';
$type = 'orders';
$name = 'requester';
$prefix = 'Ess_M2ePro_Model_Amazon_Synchronization';
$dispatcherObject = Mage::getModel('M2ePro/Connector_Server_Amazon_Dispatcher');
$dispatcherObject->processConnector($entity, $type, $name, $params, $marketplace, $account, $prefix);
//---------------------------
$this->_profiler->saveTimePoint(__METHOD__ . 'send' . $account->getId());
$this->_profiler->addEol();
}
开发者ID:xiaoguizhidao,项目名称:bb,代码行数:25,代码来源:Orders.php
示例13: processAccountMarketplace
private function processAccountMarketplace(Ess_M2ePro_Model_Account $account, Ess_M2ePro_Model_Marketplace $marketplace)
{
$title = 'Starting account "' . $account->getTitle() . '" and marketplace "' . $marketplace->getTitle() . '"';
$this->_profiler->addTitle($title);
$this->_profiler->addTimePoint(__METHOD__ . 'send' . $account->getId(), 'Update orders on Buy');
$statusString = 'Task "Orders Update Synchronization" for Rakuten.com "%s" Account and "%s" marketplace ';
$statusString .= 'is started. Please wait...';
$status = Mage::helper('M2ePro')->__($statusString, $account->getTitle(), $marketplace->getTitle());
$this->_lockItem->setStatus($status);
$changesCollection = Mage::getModel('M2ePro/Order_Change')->getCollection();
$changesCollection->addAccountFilter($account->getId());
$changesCollection->addFieldToFilter('action', Ess_M2ePro_Model_Order_Change::ACTION_UPDATE_SHIPPING);
if ($changesCollection->getSize() == 0) {
return;
}
// Update orders shipping status on Rakuten.com
//---------------------------
$params = array();
foreach ($changesCollection as $change) {
$changeParams = $change->getParams();
$params[] = array('order_id' => $change->getOrderId(), 'buy_order_id' => $changeParams['buy_order_id'], 'buy_order_item_id' => $changeParams['buy_order_item_id'], 'qty' => $changeParams['qty'], 'tracking_type' => $changeParams['tracking_type'], 'tracking_number' => $changeParams['tracking_number'], 'ship_date' => $changeParams['ship_date']);
}
/** @var $dispatcherObject Ess_M2ePro_Model_Connector_Server_Buy_Dispatcher */
$dispatcherObject = Mage::getModel('M2ePro/Buy_Connector')->getDispatcher();
$dispatcherObject->processConnector('orders', 'update', 'shipping', $params, $marketplace, $account);
$changesCollection->walk('delete');
//---------------------------
$this->_profiler->saveTimePoint(__METHOD__ . 'send' . $account->getId());
$this->_profiler->addEol();
}
开发者ID:xiaoguizhidao,项目名称:beut,代码行数:30,代码来源:Update.php
示例14: processAccountMarketplace
private function processAccountMarketplace(Ess_M2ePro_Model_Account $account, Ess_M2ePro_Model_Marketplace $marketplace)
{
$title = 'Starting account "' . $account->getTitle() . '" and marketplace "' . $marketplace->getTitle() . '"';
$this->_profiler->addTitle($title);
$this->_profiler->addTimePoint(__METHOD__ . 'send' . $account->getId(), 'Get orders from Buy');
$status = 'Task "%s" for Rakuten.com "%s" Account and "%s" marketplace is started. Please wait...';
$status = Mage::helper('M2ePro')->__($status, $this->name, $account->getTitle(), $marketplace->getTitle());
$this->_lockItem->setStatus($status);
// Get open orders from Rakuten.com for account
//---------------------------
$entity = 'tasks';
$type = 'orders_receive';
$name = 'requester';
$prefix = 'Ess_M2ePro_Model_Buy_Synchronization';
/** @var $dispatcherObject Ess_M2ePro_Model_Connector_Server_Buy_Dispatcher */
$dispatcherObject = Mage::getModel('M2ePro/Connector_Server_Buy_Dispatcher');
$dispatcherObject->processConnector($entity, $type, $name, array(), $marketplace, $account, $prefix);
//---------------------------
$this->_profiler->saveTimePoint(__METHOD__ . 'send' . $account->getId());
$this->_profiler->addEol();
}
开发者ID:xiaoguizhidao,项目名称:bb,代码行数:21,代码来源:Receive.php
示例15: updateAccountMarketplace
private function updateAccountMarketplace(Ess_M2ePro_Model_Account $accountObj, Ess_M2ePro_Model_Marketplace $marketplaceObj)
{
$this->_profiler->addTitle('Starting account "' . $accountObj->getTitle() . '" and marketplace "' . $marketplaceObj->getTitle() . '"');
$this->_profiler->addTimePoint(__METHOD__ . 'send' . $accountObj->getId(), 'Get inventory from Buy');
$status = 'Task "Update Listings Products" for Rakuten.com account: "%s" and marketplace "%s" ';
$status .= 'is started. Please wait...';
$this->_lockItem->setStatus(Mage::helper('M2ePro')->__($status, $accountObj->getTitle(), $marketplaceObj->getTitle()));
// Get all changes on Buy for account
//---------------------------
$dispatcherObject = Mage::getModel('M2ePro/Connector_Server_Buy_Dispatcher');
$dispatcherObject->processConnector('defaults', 'updateListingsProducts', 'requester', array(), $marketplaceObj, $accountObj, 'Ess_M2ePro_Model_Buy_Synchronization_Tasks');
//---------------------------
$this->_profiler->saveTimePoint(__METHOD__ . 'send' . $accountObj->getId());
$this->_profiler->addEol();
}
开发者ID:xiaoguizhidao,项目名称:bb,代码行数:15,代码来源:UpdateListingsProducts.php
示例16: getListingsProductForUpdate
private function getListingsProductForUpdate(Ess_M2ePro_Model_Account $accountObj, Ess_M2ePro_Model_Marketplace $marketplaceObj)
{
$listingTable = Mage::getResourceModel('M2ePro/Listing')->getMainTable();
/** @var $listingsCollection Mage_Core_Model_Mysql4_Collection_Abstract */
$listingsCollection = Mage::helper('M2ePro/Component_Play')->getCollection('Listing_Product');
$listingsCollection->getSelect()->join(array('l' => $listingTable), 'main_table.listing_id = l.id', array());
$listingsCollection->getSelect()->where('l.marketplace_id = ?', $marketplaceObj->getId());
$listingsCollection->getSelect()->where('l.account_id = ?', $accountObj->getId());
$listingsCollection->getSelect()->where('`second_table`.`link_info` IS NULL');
$listingsCollection->getSelect()->where('`second_table`.`play_listing_id` IS NOT NULL');
$listingsCollection->getSelect()->limit(5);
return $listingsCollection;
}
开发者ID:xiaoguizhidao,项目名称:bb,代码行数:13,代码来源:GettingProductsLinks.php
示例17: process
public function process()
{
if (!is_null($this->account) && !is_null($this->marketplace)) {
/** @var $amazonAccount Ess_M2ePro_Model_Amazon_Account */
$amazonAccount = $this->account->getChildObject();
$marketplaceDataTemp = $amazonAccount->getMarketplaceItem($this->marketplace->getId());
if (!is_null($marketplaceDataTemp)) {
$this->requestExtraData['account'] = $marketplaceDataTemp['server_hash'];
}
}
parent::process();
}
开发者ID:xiaoguizhidao,项目名称:beut,代码行数:12,代码来源:Requester.php
示例18: process
public function process()
{
if (!is_null($this->marketplace)) {
$this->requestExtraData['marketplace'] = $this->marketplace->getNativeId();
}
if (!is_null($this->account)) {
$this->requestExtraData['account'] = $this->account->getChildObject()->getServerHash();
}
if (!is_null($this->mode)) {
$this->requestExtraData['mode'] = $this->mode;
}
parent::process();
}
开发者ID:xiaoguizhidao,项目名称:devfashion,代码行数:13,代码来源:Requester.php
示例19: setLocks
public function setLocks($hash)
{
$this->listingProduct->addObjectLock(NULL, $hash);
$this->listingProduct->addObjectLock('in_action', $hash);
$this->listingProduct->addObjectLock('search_action', $hash);
$this->listingProduct->getListing()->addObjectLock(NULL, $hash);
$this->listingProduct->getListing()->addObjectLock('products_in_action', $hash);
$this->listingProduct->getListing()->addObjectLock('products_search_action', $hash);
$this->account->addObjectLock('products_in_action', $hash);
$this->account->addObjectLock('products_search_action', $hash);
$this->marketplace->addObjectLock('products_in_action', $hash);
$this->marketplace->addObjectLock('products_search_action', $hash);
$processingStatus = Ess_M2ePro_Model_Amazon_Listing_Product::GENERAL_ID_SEARCH_STATUS_PROCESSING;
$this->listingProduct->getChildObject()->setData('general_id_search_status', $processingStatus)->save();
}
开发者ID:xiaoguizhidao,项目名称:bb,代码行数:15,代码来源:Requester.php
示例20: setMarketplaceByOtherListingProduct
protected function setMarketplaceByOtherListingProduct(Ess_M2ePro_Model_Listing_Other $otherListing)
{
if (!is_null($this->marketplace) && $this->marketplace->getId() == $otherListing->getMarketplaceId()) {
return;
}
$this->marketplace = Mage::helper('M2ePro/Component_Amazon')->getObject('Marketplace', $otherListing->getMarketplaceId());
}
开发者ID:xiaoguizhidao,项目名称:beut,代码行数:7,代码来源:Mapping.php
注:本文中的Ess_M2ePro_Model_Marketplace类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论