You are here

public function Product::query in Ubercart 8.4

Overrides BooleanOperator::query().

Overrides BooleanOperator::query

File

uc_product/src/Plugin/views/filter/Product.php, line 19

Class

Product
Filter handler for "is a product".

Namespace

Drupal\uc_product\Plugin\views\filter

Code

public function query() {
  $types = uc_product_types();
  $this->query
    ->addField('node', 'type');
  $this->query
    ->addWhere($this->options['group'], 'node.type', $types, empty($this->value) ? 'NOT IN' : 'IN');
}