You are here

public function SortPluginBase::query in Views (for Drupal 7) 8.3

Called to add the sort to a query.

Overrides PluginBase::query

8 methods override SortPluginBase::query()
Broken::query in lib/Drupal/views/Plugin/views/sort/Broken.php
Called to add the sort to a query.
Date::query in lib/Drupal/views/Plugin/views/sort/Date.php
Called to add the sort to a query.
GroupByNumeric::query in lib/Drupal/views/Plugin/views/sort/GroupByNumeric.php
Called to add the field to a query.
MenuHierarchy::query in lib/Drupal/views/Plugin/views/sort/MenuHierarchy.php
Called to add the sort to a query.
NcsLastCommentName::query in lib/Views/comment/Plugin/views/sort/NcsLastCommentName.php
Called to add the sort to a query.

... See full list

File

lib/Drupal/views/Plugin/views/sort/SortPluginBase.php, line 34
Definition of Drupal\views\Plugin\views\sort\SortPluginBase.

Class

SortPluginBase
Base sort handler that has no options and performs a simple sort.

Namespace

Drupal\views\Plugin\views\sort

Code

public function query() {
  $this
    ->ensureMyTable();

  // Add the field.
  $this->query
    ->add_orderby($this->tableAlias, $this->realField, $this->options['order']);
}