public function HistoryUserTimestamp::query

Same name in this branch
  1. 9.x drupal/core/modules/node/lib/Drupal/node/Plugin/views/field/HistoryUserTimestamp.php \Drupal\node\Plugin\views\field\HistoryUserTimestamp::query()
  2. 9.x drupal/core/modules/node/lib/Drupal/node/Plugin/views/filter/HistoryUserTimestamp.php \Drupal\node\Plugin\views\filter\HistoryUserTimestamp::query()

Called to add the field to a query.

Overrides FieldPluginBase::query

File

drupal/core/modules/node/lib/Drupal/node/Plugin/views/field/HistoryUserTimestamp.php, line 61
Definition of Drupal\node\Plugin\views\field\HistoryUserTimestamp.

Class

HistoryUserTimestamp
Field handler to display the marker for new content.

Namespace

Drupal\node\Plugin\views\field

Code

public function query() {

  // Only add ourselves to the query if logged in.
  global $user;
  if (!$user->uid) {
    return;
  }
  parent::query();
}