You are here

function signup_handler_filter_signup_disabled::query in Signup 7

Same name and namespace in other branches
  1. 6.2 views/handlers/signup_handler_filter_signup_disabled.inc \signup_handler_filter_signup_disabled::query()
  2. 6 views/handlers/signup_handler_filter_signup_disabled.inc \signup_handler_filter_signup_disabled::query()

Add this filter to the query.

Due to the nature of fapi, the value and the operator have an unintended level of indirection. You will find them in $this->operator and $this->value respectively.

Overrides views_handler_filter_boolean_operator::query

File

views/handlers/signup_handler_filter_signup_disabled.inc, line 13

Class

signup_handler_filter_signup_disabled
Filter nodes based on if signups are disabled or enabled.

Code

function query() {
  $this
    ->ensure_my_table();
  $this->query
    ->add_where($this->options['group'], "{$this->table_alias}.nid " . (empty($this->value) ? 'IS' : 'IS NOT') . ' NULL');
}