|
|
@@ -142,6 +142,16 @@ class TillerManager extends AbstractManager |
|
|
|
if (!$this->isSynchronized($date, $order->id)) { |
|
|
|
// v3 |
|
|
|
if($apiVersion == 'v3') { |
|
|
|
|
|
|
|
$payments = []; |
|
|
|
$amountPayment = round($this->orderSolver->getOrderAmountWithTax($order, Order::AMOUNT_PAID) * 100); |
|
|
|
if($amountPayment) { |
|
|
|
$payments[] = [ |
|
|
|
'externalId' => ''.$order->id, |
|
|
|
'amount' => $amountPayment |
|
|
|
]; |
|
|
|
} |
|
|
|
|
|
|
|
$returnTiller = $this->tillerClient->postOrder([ |
|
|
|
'externalId' => ''.$order->id, |
|
|
|
'purchaseRequestType' => 'clickAndCollect', |
|
|
@@ -149,12 +159,7 @@ class TillerManager extends AbstractManager |
|
|
|
'order' => [ |
|
|
|
'currencyCode' => 'EUR', |
|
|
|
'itemLines' => $lines, |
|
|
|
'payments' => [ |
|
|
|
[ |
|
|
|
'externalId' => ''.$order->id, |
|
|
|
'amount' => round($this->orderSolver->getOrderAmountWithTax($order, Order::AMOUNT_PAID) * 100), |
|
|
|
] |
|
|
|
] |
|
|
|
'payments' => $payments |
|
|
|
] |
|
|
|
]); |
|
|
|
} |