Called to add the sort to a query.
Overrides SortPluginBase::query
File
- drupal/core/modules/views/lib/Drupal/views/Plugin/views/sort/Random.php, line 21
- Definition of Drupal\views\Plugin\views\sort\Random.
Class
- Random
- Handle a random sort.
Namespace
Drupal\views\Plugin\views\sort
Code
public function query() {
$this->query
->add_orderby('rand');
}