public function CreditCardPaymentMethodBase::orderLoad in Ubercart 8.4
Called when an order is being loaded with this payment method.
Parameters
\Drupal\uc_order\OrderInterface $order: The order that is being loaded.
Overrides PaymentMethodPluginBase::orderLoad
1 call to CreditCardPaymentMethodBase::orderLoad()
- CreditCardPaymentMethodBase::processPayment in payment/
uc_credit/ src/ CreditCardPaymentMethodBase.php - Process a payment through the credit card gateway.
File
- payment/
uc_credit/ src/ CreditCardPaymentMethodBase.php, line 563
Class
- CreditCardPaymentMethodBase
- Defines a base credit card payment method plugin implementation.
Namespace
Drupal\uc_creditCode
public function orderLoad(OrderInterface $order) {
// Load the CC details from the credit cache if available.
$order->payment_details = uc_credit_cache();
// Otherwise load any details that might be stored in the data array.
if (empty($order->payment_details) && isset($order->data->cc_data)) {
$order->payment_details = uc_credit_cache($order->data->cc_data);
}
}