You are here

public function RowPluginBase::query in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/views/src/Plugin/views/row/RowPluginBase.php \Drupal\views\Plugin\views\row\RowPluginBase::query()

Add anything to the query that we might need to.

Overrides PluginBase::query

1 call to RowPluginBase::query()
EntityRow::query in core/modules/views/src/Plugin/views/row/EntityRow.php
Add anything to the query that we might need to.
1 method overrides RowPluginBase::query()
EntityRow::query in core/modules/views/src/Plugin/views/row/EntityRow.php
Add anything to the query that we might need to.

File

core/modules/views/src/Plugin/views/row/RowPluginBase.php, line 141
Contains \Drupal\views\Plugin\views\row\RowPluginBase.

Class

RowPluginBase
Base class for Views row plugins.

Namespace

Drupal\views\Plugin\views\row

Code

public function query() {
  if (isset($this->base_table)) {
    if (isset($this->options['relationship']) && isset($this->view->relationship[$this->options['relationship']])) {
      $relationship = $this->view->relationship[$this->options['relationship']];
      $this->field_alias = $this->view->query
        ->addField($relationship->alias, $this->base_field);
    }
    else {
      $this->field_alias = $this->view->query
        ->addField($this->base_table, $this->base_field);
    }
  }
}