function commerce_payleap_capture_form_submit in Commerce Payleap 7
Submit handler: process a prior authorization capture via AIM.
File
- includes/
commerce_payleap.admin.inc, line 85 - Administrative forms for the Authorize.Net module.
Code
function commerce_payleap_capture_form_submit($form, &$form_state) {
$transaction = $form_state['transaction'];
$amount = $form_state['values']['amount'];
$payment_method = $form_state['payment_method'];
// Send request to payleap.
$result = commerce_payleap_transaction_request($transaction, $payment_method, $amount, 'Force');
$form_state['redirect'] = 'admin/commerce/orders/' . $form_state['order']->order_id . '/payment';
}