function views_handler_filter::init
Same name in other branches
- 7.x-3.x handlers/views_handler_filter.inc \views_handler_filter::init()
Provide some extra help to get the operator/value easier to use.
This likely has to be overridden by filters which are more complex than simple operator/value.
Overrides views_handler::init
1 call to views_handler_filter::init()
- views_handler_filter_many_to_one::init in handlers/
views_handler_filter_many_to_one.inc - Provide some extra help to get the operator/value easier to use.
1 method overrides views_handler_filter::init()
- views_handler_filter_many_to_one::init in handlers/
views_handler_filter_many_to_one.inc - Provide some extra help to get the operator/value easier to use.
File
-
handlers/
views_handler_filter.inc, line 44
Class
- views_handler_filter
- Base class for filters.
Code
function init(&$view, $options) {
parent::init($view, $options);
$this->operator = $this->options['operator'];
$this->value = $this->options['value'];
// If there are relationships in the view, allow empty should be true
// so that we can do IS NULL checks on items. Not all filters respect
// allow empty, but string and numeric do and that covers enough.
if ($this->view->display_handler
->get_option('relationships')) {
$this->definition['allow empty'] = TRUE;
}
}