You are here

function privatemsg_rules_rules_event_info in Privatemsg 7.2

Same name and namespace in other branches
  1. 6.2 privatemsg_rules/privatemsg_rules.rules.inc \privatemsg_rules_rules_event_info()
  2. 7 privatemsg_rules/privatemsg_rules.rules.inc \privatemsg_rules_rules_event_info()

Implements hook_rules_event_info().

File

privatemsg_rules/privatemsg_rules.rules.inc, line 143
Hooks and callback functions for rules.module integration.

Code

function privatemsg_rules_rules_event_info() {
  return array(
    'privatemsg_insert' => array(
      'label' => t('A message is sent'),
      'group' => t('Private messages'),
      'variables' => array(
        'privatemsg_message' => array(
          'type' => 'privatemsg_message',
          'bundle' => 'privatemsg_message',
          'label' => t('Private message'),
        ),
        'recipient' => array(
          'type' => 'user',
          'label' => t('Recipient of the message.'),
        ),
      ),
    ),
  );
}