You are here

function uc_payment_menu in Ubercart 7.3

Same name and namespace in other branches
  1. 5 payment/uc_payment/uc_payment.module \uc_payment_menu()
  2. 6.2 payment/uc_payment/uc_payment.module \uc_payment_menu()

Implements hook_menu().

File

payment/uc_payment/uc_payment.module, line 19

Code

function uc_payment_menu() {
  $items['admin/store/settings/payment'] = array(
    'title' => 'Payment methods',
    'description' => 'Choose and configure available payment methods.',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'uc_payment_methods_form',
    ),
    'access arguments' => array(
      'administer store',
    ),
    'file' => 'uc_payment.admin.inc',
  );
  $items['admin/store/settings/payment/method/%'] = array(
    'title callback' => 'uc_payment_method_title',
    'title arguments' => array(
      5,
    ),
    'description' => 'Configures a specific payment method.',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'uc_payment_method_settings_form',
      5,
    ),
    'access arguments' => array(
      'administer store',
    ),
    'file' => 'uc_payment.admin.inc',
  );
  $items += rules_ui()
    ->config_menu('admin/store/settings/payment');
  $items['admin/store/orders/%uc_order/payments'] = array(
    'title' => 'Payments',
    'description' => 'Show payments made against an order.',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'uc_payment_by_order_form',
      3,
    ),
    'access arguments' => array(
      'view payments',
    ),
    'weight' => 5,
    'type' => MENU_LOCAL_TASK,
    'file' => 'uc_payment.admin.inc',
  );
  $items['admin/store/orders/%uc_order/payments/%uc_payment/delete'] = array(
    'title' => 'Delete payment?',
    'description' => 'Delete payment?',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'uc_payment_delete_confirm_form',
      3,
      5,
    ),
    'access arguments' => array(
      'delete payments',
    ),
    'type' => MENU_CALLBACK,
    'file' => 'uc_payment.admin.inc',
  );
  return $items;
}