1); return $options; } function options_form(&$form, &$form_state) { parent::options_form($form, $form_state); $form['value']['#type'] = 'radios'; $form['value']['#title'] = t('Status'); $form['value']['#options'] = array(1 => t('Flagged'), 0 => t('Not flagged')); if ($this->options['expose']['optional']) { $form['value']['#options']['All'] = t('All'); } $form['value']['#default_value'] = empty($this->options['value']) ? 0 : $this->options['value']; $form['value']['#description'] = '
' . t('This filter is only needed if the relationship used has the "Include only flagged content" option unchecked. Otherwise, this filter is useless, because all records are already limited to flagged content.') . '
' . t('By choosing Not flagged, it is possible to create a list of content that is specifically not flagged.', array('@unflagged-url' => 'http://drupal.org/node/299335')) . '
'; } function query() { $operator = $this->value ? 'IS NOT' : 'IS'; $this->query->add_where($this->options['group'], $this->relationship . '.uid', NULL, $operator . ' NULL'); } }