You are here

function uc_fedex_ca_predicate in FedEx Shipping 6

Same name and namespace in other branches
  1. 6.2 uc_fedex.module \uc_fedex_ca_predicate()
  2. 7 uc_fedex.module \uc_fedex_ca_predicate()

Implementation of hook_ca_predicate().

Connect the FedEx quote Action and Event.

File

./uc_fedex.module, line 88
FedEx Web Services Rate / Available Services Quote

Code

function uc_fedex_ca_predicate() {
  $enabled = variable_get('uc_quote_enabled', array());
  $predicates = array(
    'uc_fedex_get_quote' => array(
      '#title' => t('Shipping quote from FedEx'),
      '#trigger' => 'get_quote_from_fedex',
      '#class' => 'uc_fedex',
      '#status' => $enabled['fedex'],
      '#actions' => array(
        array(
          '#name' => 'uc_quote_action_get_quote',
          '#title' => t('Fetch a shipping quote'),
          '#argument_map' => array(
            'order' => 'order',
            'method' => 'method',
          ),
        ),
      ),
    ),
  );
  return $predicates;
}