function commerce_cart_expiration_rules_event_info in Commerce Cart Expiration 7
Implements hook_rules_event_info().
File
- ./
commerce_cart_expiration.rules.inc, line 69 - Rules integration for Commerce Cart Expiration.
Code
function commerce_cart_expiration_rules_event_info() {
$events = array();
$events['commerce_cart_expiration_cron'] = array(
'label' => t('Commerce Cart Expiration cron is executed'),
'group' => t('Commerce Cart'),
'access callback' => 'commerce_order_rules_access',
);
$events['commerce_cart_expiration_delete_order'] = array(
'label' => t('Before deleting an expired cart'),
'group' => t('Commerce Cart'),
'variables' => array(
'commerce_order' => array(
'type' => 'commerce_order',
'label' => t('Expired cart', array(), array(
'context' => 'a drupal commerce order',
)),
),
),
'access callback' => 'commerce_order_rules_access',
);
$events['commerce_cart_expiration_reset_order'] = array(
'label' => t('Before resetting the status of an expired cart'),
'group' => t('Commerce Cart'),
'variables' => array(
'commerce_order' => array(
'type' => 'commerce_order',
'label' => t('Expired cart', array(), array(
'context' => 'a drupal commerce order',
)),
),
),
'access callback' => 'commerce_order_rules_access',
);
return $events;
}