You are here

public function VocabularyPerType::query in Drupal 8

Same name and namespace in other branches
  1. 9 core/modules/taxonomy/src/Plugin/migrate/source/d6/VocabularyPerType.php \Drupal\taxonomy\Plugin\migrate\source\d6\VocabularyPerType::query()

Return value

\Drupal\Core\Database\Query\SelectInterface

Overrides Vocabulary::query

File

core/modules/taxonomy/src/Plugin/migrate/source/d6/VocabularyPerType.php, line 20

Class

VocabularyPerType
Gets all the vocabularies based on the node types that have Taxonomy enabled.

Namespace

Drupal\taxonomy\Plugin\migrate\source\d6

Code

public function query() {
  $query = parent::query();
  $query
    ->join('vocabulary_node_types', 'nt', 'v.vid = nt.vid');
  $query
    ->fields('nt', [
    'type',
  ]);
  return $query;
}