function commerce_payflow_menu in Commerce PayPal 7.2
Implements hook_menu().
File
- modules/
payflow/ commerce_payflow.module, line 13 - Implements PayPal Payments Advanced (U.S. only) and Payflow Link Hosted Checkout pages and Transparent Redirect.
Code
function commerce_payflow_menu() {
$items = array();
// Add a menu item for capturing authorizations.
$items['admin/commerce/orders/%commerce_order/payment/%commerce_payment_transaction/payflow-link-capture'] = array(
'title' => 'Capture',
'page callback' => 'drupal_get_form',
'page arguments' => array(
'commerce_payflow_link_capture_form',
3,
5,
),
'access callback' => 'commerce_payflow_link_capture_void_access',
'access arguments' => array(
3,
5,
),
'type' => MENU_DEFAULT_LOCAL_TASK,
'context' => MENU_CONTEXT_INLINE,
'weight' => 2,
'file' => 'includes/commerce_payflow.admin.inc',
);
// Add a menu item for processing reference transactions.
$items['admin/commerce/orders/%commerce_order/payment/%commerce_payment_transaction/payflow-link-reference'] = array(
'title' => 'Reference',
'page callback' => 'drupal_get_form',
'page arguments' => array(
'commerce_payflow_link_reference_form',
3,
5,
),
'access callback' => 'commerce_payflow_link_reference_access',
'access arguments' => array(
3,
5,
),
'type' => MENU_DEFAULT_LOCAL_TASK,
'context' => MENU_CONTEXT_INLINE,
'weight' => 2,
'file' => 'includes/commerce_payflow.admin.inc',
);
// Add a menu item for voiding authorizations.
$items['admin/commerce/orders/%commerce_order/payment/%commerce_payment_transaction/payflow-link-void'] = array(
'title' => 'Void',
'page callback' => 'drupal_get_form',
'page arguments' => array(
'commerce_payflow_link_void_form',
3,
5,
),
'access callback' => 'commerce_payflow_link_capture_void_access',
'access arguments' => array(
3,
5,
),
'type' => MENU_DEFAULT_LOCAL_TASK,
'context' => MENU_CONTEXT_INLINE,
'weight' => 4,
'file' => 'includes/commerce_payflow.admin.inc',
);
// Add a menu item for refunding settled transactions.
$items['admin/commerce/orders/%commerce_order/payment/%commerce_payment_transaction/payflow-link-refund'] = array(
'title' => 'Refund',
'page callback' => 'drupal_get_form',
'page arguments' => array(
'commerce_payflow_link_refund_form',
3,
5,
),
'access callback' => 'commerce_payflow_link_refund_access',
'access arguments' => array(
3,
5,
),
'type' => MENU_DEFAULT_LOCAL_TASK,
'context' => MENU_CONTEXT_INLINE,
'weight' => 4,
'file' => 'includes/commerce_payflow.admin.inc',
);
return $items;
}