views_send.rules.inc 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. <?php
  2. /**
  3. * Implementation of hook_rules_event_info().
  4. */
  5. function views_send_rules_event_info() {
  6. $defaults = array(
  7. 'group' => t('Views Send'),
  8. );
  9. return array(
  10. 'views_send_email_sent' => $defaults + array(
  11. 'label' => t('After sending an individual email'),
  12. 'variables' => array(
  13. 'views_send_email_message' => array(
  14. 'type' => 'views_send_email_message',
  15. 'label' => t('e-mail message'),
  16. 'description' => t('All information about the message.')
  17. ),
  18. ),
  19. ),
  20. 'views_send_all_email_added_to_spool' => $defaults + array(
  21. 'label' => t('After adding all e-mails to the spool'),
  22. 'variables' => array(
  23. 'views_send_email_count' => array(
  24. 'type' => 'integer',
  25. 'label' => t('message count'),
  26. 'description' => t('The number of messages added to the spool.')
  27. ),
  28. ),
  29. ),
  30. 'views_send_email_added_to_spool' => $defaults + array(
  31. 'label' => t('After adding an individual e-mail to the spool'),
  32. 'variables' => array(
  33. 'views_send_email_message' => array(
  34. 'type' => 'views_send_email_message',
  35. 'label' => t('e-mail message'),
  36. 'description' => t('All information about the message.')
  37. ),
  38. ),
  39. ),
  40. );
  41. }
  42. /**
  43. * Implementation of hook_rules_data_info().
  44. */
  45. function views_send_rules_data_info() {
  46. return array(
  47. 'views_send_email_message' => array(
  48. 'label' => t('Views Send e-mail message'),
  49. 'group' => t('Views Send'),
  50. 'wrap' => TRUE,
  51. 'property info' => _views_send_email_message_property_info(),
  52. ),
  53. );
  54. }