function heartbeat_heartbeat_message_info in Heartbeat 6.3
Same name and namespace in other branches
- 6.4 heartbeat.module \heartbeat_heartbeat_message_info()
Implementation of hook_heartbeat_message_info
File
- ./
heartbeat.module, line 316
Code
function heartbeat_heartbeat_message_info() {
$info = array(
/**
* Default node messages
*/
2 => array(
'message' => '!username has updated !node_type "!node_title"',
'message_concat' => '!username has updated %node_title%',
'message_id' => 'heartbeat_edit_node',
'message_type' => 'normal',
'concat_args' => array(
'type' => 'summary',
'group_by' => 'user',
'group_target' => 'node_title',
'merge_separator' => ', ',
'merge_end_separator' => ' and ',
'perms' => '0',
),
'module' => 'node',
'description' => 'When editing a node, log the users activity',
'variables' => array(
'@username' => '[node:author-name-url]',
'@node_type' => '[node:type]',
'@node_title' => '[node:title-link]',
),
),
3 => array(
'message_id' => 'heartbeat_add_node',
'message_type' => 'normal',
'message' => '!username has added !node_type !node_title.',
'message_concat' => '!username has added the following !nodetypes: %node_title%.',
'concat_args' => array(
'type' => 'summary',
'group_by' => 'user',
'merge_target' => 'node_title',
'merge_separator' => ',',
'merge_end_separator' => 'and ',
'perms' => '0',
),
'module' => 'node',
'description' => 'User adds a node, save user activity',
'variables' => array(
'@username' => '[user:user-name-url]',
'@node_type' => '[node:type]',
'@node_title' => '[node:title-link]',
'@nodetypes' => '[node:type]s',
),
),
/**
* Default comment messages
*/
4 => array(
'message_id' => 'heartbeat_add_comment',
'message_type' => 'normal',
'message' => '!username replied on !title.',
'message_concat' => '!username replied on !title.',
'concat_args' => array(
'type' => 'count',
'merge_target' => 'times',
'merge_separator' => '',
'merge_end_separator' => '',
'perms' => '0',
),
'module' => 'comment',
'description' => 'user replied on some content',
'variables' => array(
'@username' => '[user:user-name-url] ',
'@title' => '[node:title-link]',
),
),
5 => array(
'message_id' => 'heartbeat_edit_comment',
'message_type' => 'normal',
'message' => '!username changed his comment on !title.',
'message_concat' => '!username changed his comment on !title several times (%times%).',
'concat_args' => array(
'type' => 'count',
'merge_target' => 'times',
'merge_separator' => '',
'merge_end_separator' => '',
'perms' => '0',
),
'module' => 'comment',
'description' => 'user changed his comment',
'variables' => array(
'@username' => '[user:user-name-url]',
'@title' => '[node:title-link]',
),
),
6 => array(
'message_id' => 'heartbeat_edit_account',
'message_type' => 'normal',
'message' => '!username\'s personal account page has been changed.',
'message_concat' => '',
'concat_args' => array(
'type' => 'single',
'merge_target' => '',
'merge_separator' => '',
'merge_end_separator' => '',
'perms' => '0',
),
'module' => 'user',
'description' => 'user changed his/her account',
'variables' => array(
'@username' => '[user:user-name-url]',
),
),
);
return $info;
}