public function process() { $result = parent::process(); foreach ($this->messages as $message) { $priorityMessage = Ess_M2ePro_Model_ListingsLogs::PRIORITY_MEDIUM; if ($message[parent::MESSAGE_TYPE_KEY] == parent::MESSAGE_TYPE_ERROR) { $priorityMessage = Ess_M2ePro_Model_ListingsLogs::PRIORITY_HIGH; } $this->addListingsProductsLogsMessage($this->listingProduct, $message, $priorityMessage); } return $result; }
public function process() { $result = parent::process(); foreach ($this->messages as $message) { $priorityMessage = Ess_M2ePro_Model_ListingsLogs::PRIORITY_MEDIUM; if ($message[parent::MESSAGE_TYPE_KEY] == parent::MESSAGE_TYPE_ERROR) { $priorityMessage = Ess_M2ePro_Model_ListingsLogs::PRIORITY_HIGH; } $this->addListingsLogsMessage($message, $priorityMessage); } if (isset($result['result'])) { foreach ($result['result'] as $tempIdProduct => $tempResultProduct) { if (!isset($tempResultProduct['messages'])) { continue; } $listingProductInArray = NULL; foreach ($this->listingsProducts as $listingProduct) { if ($tempIdProduct == $listingProduct->getId()) { $listingProductInArray = $listingProduct; break; } } if (is_null($listingProductInArray)) { continue; } foreach ($tempResultProduct['messages'] as $message) { $priorityMessage = Ess_M2ePro_Model_ListingsLogs::PRIORITY_MEDIUM; if ($message[parent::MESSAGE_TYPE_KEY] == parent::MESSAGE_TYPE_ERROR) { $priorityMessage = Ess_M2ePro_Model_ListingsLogs::PRIORITY_HIGH; } $this->addListingsProductsLogsMessage($listingProductInArray, $message, $priorityMessage); } } } return $result; }