1
0
Fork 0
mirror of synced 2025-04-03 22:03:34 +03:00

Change order number transfer for history

This commit is contained in:
dima-uryvskiy 2022-03-15 11:20:34 +03:00
parent 7f04fe822a
commit 529e9490eb

View file

@ -236,12 +236,14 @@ if (!class_exists('WC_Retailcrm_History')) :
$wcOrder->calculate_totals();
}
$wcOrderNumber = $wcOrder->get_order_number();
if (
$order['number'] != $wcOrderId
$order['number'] != $wcOrderNumber
&& isset($this->retailcrmSettings['update_number'])
&& $this->retailcrmSettings['update_number'] == WC_Retailcrm_Base::YES
) {
$order['number'] = $wcOrderId;
$order['number'] = $wcOrderNumber;
$this->retailcrm->ordersEdit($order, 'id');
}