function elasticsearch_watchdog_form_system_logging_settings_alter in Elasticsearch Connector 7
Same name and namespace in other branches
- 7.2 modules/elasticsearch_watchdog/elasticsearch_watchdog.module \elasticsearch_watchdog_form_system_logging_settings_alter()
Implements hook_form_FORM_ID_alter() for system_logging_settings().
File
- modules/
elasticsearch_watchdog/ elasticsearch_watchdog.module, line 160 - Created on Jan 06, 2014
Code
function elasticsearch_watchdog_form_system_logging_settings_alter(&$form, $form_state) {
$form['elasticsearch_watchdog_ttl'] = array(
'#type' => 'textfield',
'#title' => t('Elasticsearch TTL Interval'),
'#default_value' => variable_get('elasticsearch_watchdog_ttl', ELASTICSEARCH_WATCHDOG_DEFAULT_INTERVAL),
'#element_validate' => array(
'_elasticsearch_connector_validate_ttl_field',
),
'#description' => t('Use format like 1d. Suffix can be d (days), m (minutes), h (hours), ms (milliseconds) or w (weeks).' . ' You can dynamically update the default interval.' . ' However it won\'t change the TTL of already indexed messages but will be used for future logs.'),
);
$form['actions']['#weight'] = 1;
}