You are here

function forena_settings in Forena Reports 6.2

Same name and namespace in other branches
  1. 8 forena_ui/forena.admin.inc \forena_settings()
  2. 6 forena.admin.inc \forena_settings()
  3. 7.5 forena.admin.inc \forena_settings()
  4. 7 forena.admin.inc \forena_settings()
  5. 7.2 forena.admin.inc \forena_settings()
  6. 7.3 forena.admin.inc \forena_settings()
  7. 7.4 forena.admin.inc \forena_settings()

Forena admin settings form

1 string reference to 'forena_settings'
forena_menu in ./forena.module
Implementation of hook_menu.

File

./forena.admin.inc, line 361

Code

function forena_settings() {
  $report_path = forena_report_path();
  $form['sync_overwrite'] = array(
    '#type' => 'checkbox',
    '#title' => t('Revert all delivered reports to orignial'),
    '#description' => t('All customizations to module delivered reports will be lost.'),
  );
  $form['sync'] = array(
    '#type' => 'submit',
    '#value' => t('Clear Cache'),
    '#submit' => array(
      'forena_settings_sync_submit',
    ),
  );
  $form['forena_report_repos'] = array(
    '#type' => 'textfield',
    '#title' => t('Report Repository'),
    '#description' => t('Indicate the directory that you want to use for your reports.  In order for you to ' . 'to be able to save reports, this directory should be writable by the web user. Relative' . 'paths should be entered relative to the base path of your drupal installation.'),
    '#default_value' => $report_path,
  );
  $form['forena_last_report_path'] = array(
    '#type' => 'value',
    '#value' => forena_report_path(),
  );
  $form['forena_input_format'] = filter_form(variable_get('forena_input_format', FILTER_FORMAT_DEFAULT), NULL, array(
    'forena_input_format',
  ));
  $form['forena_default_form'] = array(
    '#type' => 'textfield',
    '#title' => t('Default report form'),
    '#description' => t('Indicates the default style sheet(s) that will be used when no tag is present in the report.'),
    '#default_value' => variable_get('forena_default_form', ''),
  );
  $form = system_settings_form($form);
  $form['#submit'][] = 'forena_settings_submit';
  return $form;
}