You are here

function notifications_lite_event in Notifications 6.3

Build notifications event

1 call to notifications_lite_event()
notifications_lite_notifications_post in notifications_lite/notifications_lite.module
Post message using notifications

File

notifications_lite/notifications_lite.module, line 153
Simple notifications API

Code

function notifications_lite_event($message, $params, $counter = 1) {

  // Build and store simple event
  $event = array(
    'module' => 'notifications',
    'uid' => 0,
    'oid' => 0,
    'type' => 'lite',
    'action' => $message['action'],
    'params' => $params + array(
      'subject' => $message['subject'],
      'body' => $message['body'],
    ),
    'queue' => FALSE,
    // Do not send to notifications queue, save some queries
    'counter' => $counter,
    // As many as destinations
    'language' => $message['language']->language,
  );
  return notifications_event($event);
}