public function VocabularyVid::title in Drupal 9
Same name and namespace in other branches
- 8 core/modules/taxonomy/src/Plugin/views/argument/VocabularyVid.php \Drupal\taxonomy\Plugin\views\argument\VocabularyVid::title()
Override the behavior of title(). Get the name of the vocabulary.
Overrides NumericArgument::title
File
- core/
modules/ taxonomy/ src/ Plugin/ views/ argument/ VocabularyVid.php, line 57
Class
- VocabularyVid
- Argument handler to accept a vocabulary id.
Namespace
Drupal\taxonomy\Plugin\views\argumentCode
public function title() {
$vocabulary = $this->vocabularyStorage
->load($this->argument);
if ($vocabulary) {
return $vocabulary
->label();
}
return $this
->t('No vocabulary');
}