commit
581b7de410
@ -606,7 +606,7 @@ class RetailCrmHistory
|
|||||||
foreach ($optionsLegalDetails[$personType] as $key => $orderProp) {
|
foreach ($optionsLegalDetails[$personType] as $key => $orderProp) {
|
||||||
if (array_key_exists($key, $order)) {
|
if (array_key_exists($key, $order)) {
|
||||||
$somePropValue = $propertyCollection->getItemByOrderPropertyId($propsKey[$orderProp]['ID']);
|
$somePropValue = $propertyCollection->getItemByOrderPropertyId($propsKey[$orderProp]['ID']);
|
||||||
self::setProp($somePropValue, $order[$key]);
|
self::setProp($somePropValue, RCrmActions::fromJSON($order[$key]));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -994,10 +994,15 @@ class RetailCrmHistory
|
|||||||
|
|
||||||
if (isset($orderCrm['delivery']['service']['code'])) {
|
if (isset($orderCrm['delivery']['service']['code'])) {
|
||||||
$deliveryCode = \Bitrix\Sale\Delivery\Services\Manager::getCodeById($deliveryId);
|
$deliveryCode = \Bitrix\Sale\Delivery\Services\Manager::getCodeById($deliveryId);
|
||||||
|
$serviceCode = $orderCrm['delivery']['service']['code'];
|
||||||
|
$services = \Bitrix\Sale\Delivery\Services\Manager::getService($deliveryId)->getProfilesList();
|
||||||
|
if (!array_key_exists($serviceCode, $services)) {
|
||||||
|
$serviceCode = strtoupper($serviceCode);
|
||||||
|
$serviceCode = str_replace(array('-'), "_", $serviceCode);
|
||||||
|
}
|
||||||
if ($deliveryCode) {
|
if ($deliveryCode) {
|
||||||
try {
|
try {
|
||||||
$deliveryService = \Bitrix\Sale\Delivery\Services\Manager::getObjectByCode($deliveryCode . ':' . $orderCrm['delivery']['service']['code']);
|
$deliveryService = \Bitrix\Sale\Delivery\Services\Manager::getObjectByCode($deliveryCode . ':' . $serviceCode);
|
||||||
} catch (Bitrix\Main\SystemException $systemException) {
|
} catch (Bitrix\Main\SystemException $systemException) {
|
||||||
RCrmActions::eventLog('RetailCrmHistory::deliveryEdit', '\Bitrix\Sale\Delivery\Services\Manager::getObjectByCode', $systemException->getMessage());
|
RCrmActions::eventLog('RetailCrmHistory::deliveryEdit', '\Bitrix\Sale\Delivery\Services\Manager::getObjectByCode', $systemException->getMessage());
|
||||||
}
|
}
|
||||||
|
@ -740,7 +740,7 @@ if (file_exists($_SERVER["DOCUMENT_ROOT"]."/bitrix/php_interface/retailcrm/expor
|
|||||||
BX(obj.id.replace('SKU','PRODUCT')).value = 'none';
|
BX(obj.id.replace('SKU','PRODUCT')).value = 'none';
|
||||||
var bid = obj.id.replace('SKU','PRODUCT');
|
var bid = obj.id.replace('SKU','PRODUCT');
|
||||||
$("#" + bid).siblings('#highloadblock').remove();
|
$("#" + bid).siblings('#highloadblock').remove();
|
||||||
} else {
|
} else if(BX(obj.id.replace('PRODUCT','SKU'))) {
|
||||||
BX(obj.id.replace('PRODUCT','SKU')).value = 'none';
|
BX(obj.id.replace('PRODUCT','SKU')).value = 'none';
|
||||||
var bid = obj.id.replace('PRODUCT','SKU');
|
var bid = obj.id.replace('PRODUCT','SKU');
|
||||||
$("#" + bid).siblings('#highloadblock').remove();
|
$("#" + bid).siblings('#highloadblock').remove();
|
||||||
|
@ -595,7 +595,7 @@ if (!empty($oldValues)) {
|
|||||||
BX(obj.id.replace('SKU','PRODUCT')).value = 'none';
|
BX(obj.id.replace('SKU','PRODUCT')).value = 'none';
|
||||||
var bid = obj.id.replace('SKU','PRODUCT');
|
var bid = obj.id.replace('SKU','PRODUCT');
|
||||||
$("#" + bid).siblings('#highloadblock').remove();
|
$("#" + bid).siblings('#highloadblock').remove();
|
||||||
} else {
|
} else if(BX(obj.id.replace('PRODUCT','SKU'))){
|
||||||
BX(obj.id.replace('PRODUCT','SKU')).value = 'none';
|
BX(obj.id.replace('PRODUCT','SKU')).value = 'none';
|
||||||
var bid = obj.id.replace('PRODUCT','SKU');
|
var bid = obj.id.replace('PRODUCT','SKU');
|
||||||
$("#" + bid).siblings('#highloadblock').remove();
|
$("#" + bid).siblings('#highloadblock').remove();
|
||||||
|
Loading…
Reference in New Issue
Block a user