You are here

function EntityInOperator::opSimple in EntityFieldQuery Views Backend 8

Overrides InOperator::opSimple

File

src/Plugin/views/filter/EntityInOperator.php, line 23
Contains \Drupal\efq_views\Plugin\views\filter\EntityInOperator.

Class

EntityInOperator
Handle matching of multiple options selectable via checkboxes

Namespace

Drupal\efq_views\Plugin\views\filter

Code

function opSimple() {
  if (empty($this->value)) {
    return;
  }

  // We use array_values() because the checkboxes keep keys and that can cause
  // array addition problems.
  $this->query->query
    ->entityCondition($this->real_field, array_values($this->value), $this->operator);
}