Commit e26c1c47 authored by Andy Fowlston's avatar Andy Fowlston Committed by Ivan Trokhanenko
Browse files

Issue #3248172 by AndyF: Send order number/ID as invoice number

parent 63f1fd3d
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -132,6 +132,10 @@ class Onsite extends OnsitePaymentGatewayBase implements OnsiteInterface {
      'ssl_amount' => $amount,
      'ssl_token' => $payment_method_token,
    ];
    $order = $payment->getOrder();
    if ($order) {
      $post_data['ssl_invoice_number'] = $order->getOrderNumber() ?: $order->id();
    }
    if ($this->configuration['multicurrency']) {
      $post_data['ssl_transaction_currency'] = $payment->getAmount()->getCurrencyCode();
    }