function commerce_recurring_rules_event_info in Commerce Recurring Framework 7.2
Same name and namespace in other branches
- 7 commerce_recurring.rules.inc \commerce_recurring_rules_event_info()
Implements hook_rules_event_info().
File
- ./
commerce_recurring.rules.inc, line 13 - Rules integration for recurring entities.
Code
function commerce_recurring_rules_event_info() {
$events = array();
$events['commerce_recurring_paid_full'] = array(
'label' => t('Recurring order is paid in full'),
'group' => t('Commerce recurring'),
'variables' => array(
'commerce_order' => array(
'type' => 'commerce_order',
'label' => t('Commerce order'),
),
'commerce_recurring' => array(
'type' => 'commerce_recurring',
'label' => t('Commerce recurring entity'),
),
'number_of_orders' => array(
'type' => 'decimal',
'label' => t('Number of orders'),
'description' => t('Number of orders associated to the recurring entity so reacting to the first or nth one is easier.'),
'default value' => 0,
),
),
'access callback' => 'commerce_order_rules_access',
);
$events['commerce_recurring_stop_recurring'] = array(
'label' => t('Stop a recurring entity'),
'group' => t('Commerce recurring'),
'variables' => array(
'commerce_recurring' => array(
'type' => 'commerce_recurring',
'label' => t('Commerce recurring entity'),
),
),
'access callback' => 'commerce_order_rules_access',
);
$events['commerce_recurring_cron'] = array(
'label' => t('Commerce Recurring cron is executed'),
'group' => t('Commerce recurring'),
'access callback' => 'commerce_order_rules_access',
);
return $events;
}