From 686548ab6382767d5274042b69316432443a8bd6 Mon Sep 17 00:00:00 2001 From: gorokh Date: Wed, 12 Feb 2020 12:25:39 +0300 Subject: [PATCH] =?UTF-8?q?=D0=BF=D0=BE=D0=BF=D1=80=D0=B0=D0=B2=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=D0=B0=20=D0=BF=D0=B5=D1=80=D0=B5=D0=B4=D0=B0=D1=87?= =?UTF-8?q?=D0=B0=20=D1=81=D0=BA=D0=B8=D0=B4=D0=BA=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../classes/general/order/RetailCrmOrder_v5.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/intaro.retailcrm/classes/general/order/RetailCrmOrder_v5.php b/intaro.retailcrm/classes/general/order/RetailCrmOrder_v5.php index 7dba46e4..da3a3a95 100644 --- a/intaro.retailcrm/classes/general/order/RetailCrmOrder_v5.php +++ b/intaro.retailcrm/classes/general/order/RetailCrmOrder_v5.php @@ -212,6 +212,12 @@ class RetailCrmOrder $item['discountManualPercent'] = 0; $item['initialPrice'] = $initialPrice; + $dpItem = $product['BASE_PRICE'] - $product['PRICE']; + if ( $dpItem > 0) { + $item['discountManualAmount'] = $dpItem; + $item['initialPrice'] = (double)$product['BASE_PRICE']; + } + $order['items'][] = $item; if ($send && $dimensionsSetting == 'Y') {