You are here

class NodeCounterTimestamp in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/statistics/src/Plugin/views/field/NodeCounterTimestamp.php \Drupal\statistics\Plugin\views\field\NodeCounterTimestamp
  2. 9 core/modules/statistics/src/Plugin/views/field/NodeCounterTimestamp.php \Drupal\statistics\Plugin\views\field\NodeCounterTimestamp

Field handler to display the most recent time the node has been viewed.

Plugin annotation

@ViewsField("node_counter_timestamp");

Hierarchy

  • class \Drupal\views\Plugin\views\field\Date extends \Drupal\views\Plugin\views\field\FieldPluginBase

Expanded class hierarchy of NodeCounterTimestamp

File

core/modules/statistics/src/Plugin/views/field/NodeCounterTimestamp.php, line 15

Namespace

Drupal\statistics\Plugin\views\field
View source
class NodeCounterTimestamp extends Date {

  /**
   * {@inheritdoc}
   */
  public function access(AccountInterface $account) {
    return $account
      ->hasPermission('view post access counter');
  }

}

Members

Namesort descending Modifiers Type Description Overrides
Date::$dateFormatStorage protected property The date format storage.
Date::$dateFormatter protected property The date formatter service.
Date::buildOptionsForm public function
Date::create public static function
Date::defineOptions protected function
Date::render public function 1
Date::__construct public function Constructs a new Date object.
NodeCounterTimestamp::access public function