mirror of
https://github.com/retailcrm/opencart-module.git
synced 2024-11-25 06:36:06 +03:00
fix order send fail when delivery code is an empty string
This commit is contained in:
parent
af8eb0beee
commit
7156caed81
@ -136,7 +136,9 @@ class ModelRetailcrmOrder extends Model {
|
|||||||
$country = (isset($order_data['shipping_country'])) ? $order_data['shipping_country'] : '' ;
|
$country = (isset($order_data['shipping_country'])) ? $order_data['shipping_country'] : '' ;
|
||||||
|
|
||||||
$order['delivery'] = array(
|
$order['delivery'] = array(
|
||||||
'code' => $settings['retailcrm_delivery'][$delivery_code],
|
'code' => !empty($settings['retailcrm_delivery'][$delivery_code])
|
||||||
|
? $settings['retailcrm_delivery'][$delivery_code]
|
||||||
|
: null,
|
||||||
'cost' => $deliveryCost,
|
'cost' => $deliveryCost,
|
||||||
'address' => array(
|
'address' => array(
|
||||||
'index' => $order_data['shipping_postcode'],
|
'index' => $order_data['shipping_postcode'],
|
||||||
|
Loading…
Reference in New Issue
Block a user