function views_handler_sort::expose_form
Overrides views_handler::expose_form
File
-
handlers/
views_handler_sort.inc, line 202
Class
- views_handler_sort
- Base sort handler that has no options and performs a simple sort.
Code
public function expose_form(&$form, &$form_state) {
// #flatten will move everything from $form['expose'][$key] to $form[$key]
// prior to rendering. That's why the pre_render for it needs to run first,
// so that when the next pre_render (the one for fieldsets) runs, it gets
// the flattened data.
array_unshift($form['#pre_render'], 'views_ui_pre_render_flatten_data');
$form['expose']['#flatten'] = TRUE;
$form['expose']['label'] = array(
'#type' => 'textfield',
'#default_value' => $this->options['expose']['label'],
'#title' => t('Label'),
'#required' => TRUE,
'#size' => 40,
'#weight' => -1,
);
}