You are here

function mob_queue_settings in Drush Queue Handling 7

Implements hook_form_alter().

Switching off queue run on cron run.

1 string reference to 'mob_queue_settings'
mob_queue_menu in ./mob_queue.module
Implements hook_menu().

File

./mob_queue.module, line 30
Module for the cron queue management - a small yet powerful queue tool

Code

function mob_queue_settings($form) {
  $queues = module_invoke_all('cron_queue_info');
  $form['mob_qinfo'] = array(
    '#type' => 'fieldset',
    '#title' => t('Drush Queue Handling'),
  );
  foreach ($queues as $name => $queue) {
    $form['mob_qinfo']['mob_queue_' . $name] = array(
      '#type' => 'checkbox',
      '#title' => $name,
      '#description' => t('Turn off queue @name process in cron.', array(
        '@name' => $name,
      )),
      '#default_value' => variable_get('mob_queue_' . $name, 0),
      '#weight' => 1,
    );
  }
  return system_settings_form($form);
}