function notifications_admin_queue_summary in Notifications 6.3
Same name and namespace in other branches
- 5 notifications.admin.inc \notifications_admin_queue_summary()
- 6 notifications.admin.inc \notifications_admin_queue_summary()
- 6.2 notifications.admin.inc \notifications_admin_queue_summary()
Summary of queued notifications
2 calls to notifications_admin_queue_summary()
- notifications_admin_queue in ./
notifications.admin.inc - Admin queue management
- notifications_admin_status_page in ./
notifications.admin.inc - Current subscriptions page
File
- ./
notifications.admin.inc, line 384
Code
function notifications_admin_queue_summary() {
$output = '';
// Queue status
$send_intervals = _notifications_send_intervals();
$header = array(
t('Send interval'),
t('Number'),
);
$count = 0;
$result = db_query("SELECT send_interval, count(*) AS count FROM {notifications_queue} WHERE cron = 1 GROUP BY send_interval");
$rows = array();
while ($stype = db_fetch_object($result)) {
$rows[] = array(
$send_intervals[$stype->send_interval],
$stype->count,
);
$count += $stype->count;
}
$output .= theme('table', $header, $rows);
$output .= t('Total: %number', array(
'%number' => $count,
));
return theme('box', t('Notifications in queue'), $output);
}