function ArgumentPluginBase::summaryName

Same name and namespace in other branches
  1. 8.9.x core/modules/views/src/Plugin/views/argument/ArgumentPluginBase.php \Drupal\views\Plugin\views\argument\ArgumentPluginBase::summaryName()
  2. 10 core/modules/views/src/Plugin/views/argument/ArgumentPluginBase.php \Drupal\views\Plugin\views\argument\ArgumentPluginBase::summaryName()
  3. 11.x core/modules/views/src/Plugin/views/argument/ArgumentPluginBase.php \Drupal\views\Plugin\views\argument\ArgumentPluginBase::summaryName()

Provides the name to use for the summary, defaults to the name field.

Parameters

$data: The query results for the row.

2 calls to ArgumentPluginBase::summaryName()
MonthDate::summaryName in core/modules/views/src/Plugin/views/argument/MonthDate.php
Provides the name to use for the summary, defaults to the name field.
StringArgument::summaryName in core/modules/views/src/Plugin/views/argument/StringArgument.php
Provides the name to use for the summary, defaults to the name field.
8 methods override ArgumentPluginBase::summaryName()
DayDate::summaryName in core/modules/views/src/Plugin/views/argument/DayDate.php
Provides the name to use for the summary, defaults to the name field.
FullDate::summaryName in core/modules/views/src/Plugin/views/argument/FullDate.php
Provides the name to use for the summary, defaults to the name field.
LanguageArgument::summaryName in core/modules/views/src/Plugin/views/argument/LanguageArgument.php
Overrides \Drupal\views\Plugin\views\argument\ArgumentPluginBase::summaryName().
MonthDate::summaryName in core/modules/views/src/Plugin/views/argument/MonthDate.php
Provides the name to use for the summary, defaults to the name field.
NumberListField::summaryName in core/modules/options/src/Plugin/views/argument/NumberListField.php
Provides the name to use for the summary, defaults to the name field.

... See full list

File

core/modules/views/src/Plugin/views/argument/ArgumentPluginBase.php, line 962

Class

ArgumentPluginBase
Base class for argument (contextual filter) handler plugins.

Namespace

Drupal\views\Plugin\views\argument

Code

public function summaryName($data) {
    $value = (string) $data->{$this->name_alias};
    if ($value === '' && isset($this->definition['empty field name'])) {
        $value = $this->definition['empty field name'];
    }
    return $value;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.