Zaktualizowano wersję na 0.226, dodano opcję faktury do zamówienia oraz wprowadzono zmiany w strukturze bazy danych i logice obsługi zamówień.
This commit is contained in:
11
cron.php
11
cron.php
@@ -540,7 +540,7 @@ if ( $apilo_settings['enabled'] and $apilo_settings['sync_orders'] and $apilo_se
|
||||
|
||||
$postData = [
|
||||
'idExternal' => $order['id'],
|
||||
'isInvoice' => false,
|
||||
'isInvoice' => $order['firm_name'] ? true : false,
|
||||
'customerLogin' => $order['client_email'],
|
||||
'paymentType' => (int)\front\factory\ShopPaymentMethod::get_apilo_payment_method_id( $order['payment_method_id'] ),
|
||||
'originalCurrency' => 'PLN',
|
||||
@@ -572,6 +572,15 @@ if ( $apilo_settings['enabled'] and $apilo_settings['sync_orders'] and $apilo_se
|
||||
'platformId' => $apilo_settings['platform-id']
|
||||
];
|
||||
|
||||
if ( $order['firm_name'] )
|
||||
{
|
||||
$postData['addressInvoice']['name'] = $order['firm_name'];
|
||||
$postData['addressInvoice']['streetName'] = $order['firm_street'];
|
||||
$postData['addressInvoice']['city'] = $order['firm_city'];
|
||||
$postData['addressInvoice']['zipCode'] = $order['firm_postal_code'];
|
||||
$postData['addressInvoice']['companyTaxNumber'] = $order['firm_nip'];
|
||||
}
|
||||
|
||||
// jeżeli paczkomat
|
||||
if ( $order['inpost_paczkomat'] )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user