error codes update;
This commit is contained in:
parent
12d768772f
commit
1e16626047
@ -68,6 +68,7 @@ class ICrmOrderActions
|
|||||||
// pack mode enable / disable
|
// pack mode enable / disable
|
||||||
// can send data evry 500 rows
|
// can send data evry 500 rows
|
||||||
if (!$steps) {
|
if (!$steps) {
|
||||||
|
|
||||||
while ($arOrder = $dbOrder->GetNext()) { //here orders by id asc; with offset
|
while ($arOrder = $dbOrder->GetNext()) { //here orders by id asc; with offset
|
||||||
|
|
||||||
$order = self::orderCreate($arOrder['ID'], $api, $arParams);
|
$order = self::orderCreate($arOrder['ID'], $api, $arParams);
|
||||||
@ -84,7 +85,7 @@ class ICrmOrderActions
|
|||||||
$orders = $api->orderUpload($resOrders);
|
$orders = $api->orderUpload($resOrders);
|
||||||
|
|
||||||
// error pushing orders
|
// error pushing orders
|
||||||
if ($api->getStatusCode() != 200) {
|
if ($api->getStatusCode() != 201) {
|
||||||
//handle err
|
//handle err
|
||||||
self::eventLog('ICrmOrderActions::uploadOrders', 'IntaroCrm\RestApi::orderUpload', $api->getLastError());
|
self::eventLog('ICrmOrderActions::uploadOrders', 'IntaroCrm\RestApi::orderUpload', $api->getLastError());
|
||||||
|
|
||||||
@ -92,6 +93,7 @@ class ICrmOrderActions
|
|||||||
return false; // in pack mode return errors
|
return false; // in pack mode return errors
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
} else { // package mode (by default runs after install)
|
} else { // package mode (by default runs after install)
|
||||||
$orderCount = 0;
|
$orderCount = 0;
|
||||||
|
|
||||||
@ -112,7 +114,7 @@ class ICrmOrderActions
|
|||||||
$orders = $api->orderUpload($resOrders);
|
$orders = $api->orderUpload($resOrders);
|
||||||
|
|
||||||
// error pushing orders
|
// error pushing orders
|
||||||
if ($api->getStatusCode() != 200) {
|
if ($api->getStatusCode() != 201) {
|
||||||
//handle err
|
//handle err
|
||||||
self::eventLog('ICrmOrderActions::uploadOrders', 'IntaroCrm\RestApi::orderUpload', $api->getLastError());
|
self::eventLog('ICrmOrderActions::uploadOrders', 'IntaroCrm\RestApi::orderUpload', $api->getLastError());
|
||||||
|
|
||||||
@ -130,7 +132,7 @@ class ICrmOrderActions
|
|||||||
$orders = $api->orderUpload($resOrders);
|
$orders = $api->orderUpload($resOrders);
|
||||||
|
|
||||||
// error pushing orders
|
// error pushing orders
|
||||||
if ($api->getStatusCode() != 200) {
|
if ($api->getStatusCode() != 201) {
|
||||||
//handle err
|
//handle err
|
||||||
self::eventLog('ICrmOrderActions::uploadOrders', 'IntaroCrm\RestApi::orderUpload', $api->getLastError());
|
self::eventLog('ICrmOrderActions::uploadOrders', 'IntaroCrm\RestApi::orderUpload', $api->getLastError());
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<?
|
<?
|
||||||
$arModuleVersion = array(
|
$arModuleVersion = array(
|
||||||
'VERSION' => '0.3.5',
|
'VERSION' => '0.3.5',
|
||||||
'VERSION_DATE' => '2013-07-24 17:28:00',
|
'VERSION_DATE' => '2013-07-24 18:27:00',
|
||||||
);
|
);
|
||||||
|
Loading…
Reference in New Issue
Block a user