function views_plugin_style_watchdog_table::options_form in Views Watchdog 6.2
Same name and namespace in other branches
- 6.3 views/plugins/views_plugin_style_watchdog_table.inc \views_plugin_style_watchdog_table::options_form()
- 6 views/plugins/views_plugin_style_watchdog_table.inc \views_plugin_style_watchdog_table::options_form()
- 7.3 views/plugins/views_plugin_style_watchdog_table.inc \views_plugin_style_watchdog_table::options_form()
File
- views/
plugins/ views_plugin_style_watchdog_table.inc, line 33 - Views style plugin for the views_watchdog module.
Class
- views_plugin_style_watchdog_table
- Provides style options for watchdog tables.
Code
function options_form(&$form, &$form_state) {
parent::options_form($form, $form_state);
$form['watchdog_table_type'] = array(
'#type' => 'checkbox',
'#title' => t('Add CSS classes to each table row based on type.'),
'#default_value' => !empty($this->options['watchdog_table_type']),
);
$form['watchdog_table_type_class'] = array(
'#type' => 'textfield',
'#title' => t('Type class'),
'#description' => t('The CSS class to apply to the row. Replacement patterns: [type]'),
'#default_value' => !empty($this->options['watchdog_table_type_class']) ? $this->options['watchdog_table_type_class'] : 'dblog-[type]',
'#process' => array(
'views_process_dependency',
),
'#dependency' => array(
'edit-style-options-watchdog-table-type' => array(
1,
),
),
);
$form['watchdog_table_severity'] = array(
'#type' => 'checkbox',
'#title' => t('Add CSS classes to each table row based on severity level.'),
'#default_value' => !empty($this->options['watchdog_table_severity']),
);
$form['watchdog_table_severity_class'] = array(
'#type' => 'textfield',
'#title' => t('Severity class'),
'#description' => t('The CSS class to apply to the row. Replacement patterns: [severity]'),
'#default_value' => !empty($this->options['watchdog_table_severity_class']) ? $this->options['watchdog_table_severity_class'] : 'dblog-[severity]',
'#process' => array(
'views_process_dependency',
),
'#dependency' => array(
'edit-style-options-watchdog-table-severity' => array(
1,
),
),
);
}