function notifications_admin_queue_process in Notifications 6.3
Same name and namespace in other branches
- 5 notifications.admin.inc \notifications_admin_queue_process()
- 6 notifications.admin.inc \notifications_admin_queue_process()
- 6.2 notifications.admin.inc \notifications_admin_queue_process()
Queue operations callback
1 string reference to 'notifications_admin_queue_process'
- notifications_queue_operations in ./
notifications.admin.inc - List of queue operations
File
- ./
notifications.admin.inc, line 504
Code
function notifications_admin_queue_process($op) {
switch ($op) {
case 'reset queue':
db_query("DELETE FROM {notifications_queue}");
db_query("DELETE FROM {notifications_event}");
drupal_set_message(t('The queue has been reset.'));
break;
case 'test run':
notifications_process('option', 'test', TRUE);
notifications_process_run(FALSE);
break;
case 'test send':
notifications_process('option', 'keep', TRUE);
notifications_process_run(FALSE);
break;
case 'clean queue':
// Delete logs and clean up events
notifications_queue_clean(array(
'cron' => 0,
));
break;
}
}