function RelationshipPluginBase::calculateDependencies

Same name in other branches
  1. 9 core/modules/views/src/Plugin/views/relationship/RelationshipPluginBase.php \Drupal\views\Plugin\views\relationship\RelationshipPluginBase::calculateDependencies()
  2. 8.9.x core/modules/views/src/Plugin/views/relationship/RelationshipPluginBase.php \Drupal\views\Plugin\views\relationship\RelationshipPluginBase::calculateDependencies()
  3. 10 core/modules/views/src/Plugin/views/relationship/RelationshipPluginBase.php \Drupal\views\Plugin\views\relationship\RelationshipPluginBase::calculateDependencies()

Overrides HandlerBase::calculateDependencies

1 method overrides RelationshipPluginBase::calculateDependencies()
NodeTermData::calculateDependencies in core/modules/taxonomy/src/Plugin/views/relationship/NodeTermData.php
Calculates dependencies for the configured plugin.

File

core/modules/views/src/Plugin/views/relationship/RelationshipPluginBase.php, line 177

Class

RelationshipPluginBase
Relationship plugin base.

Namespace

Drupal\views\Plugin\views\relationship

Code

public function calculateDependencies() {
    $dependencies = parent::calculateDependencies();
    // Add the provider of the relationship's base table to the dependencies.
    $table_data = $this->getViewsData()
        ->get($this->definition['base']);
    $dependencies['module'][] = $table_data['table']['provider'];
    return $dependencies;
}

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