You are here

taxonomy_term_reference.inc in Corresponding Entity References 7.3

Contains the CER plugin for Taxonomy Term Reference fields.

File

includes/fields/taxonomy_term_reference.inc
View source
<?php

/**
 * @file
 * Contains the CER plugin for Taxonomy Term Reference fields.
 */
class CerTaxonomyTermReferenceField extends CerField {

  /**
   * Implements CerField::getTargetType().
   */
  public function getTargetType() {
    return 'taxonomy_term';
  }

  /**
   * @override CerField::getTargetBundles().
   */
  public function getTargetBundles() {
    $bundles = array();
    foreach ($this->settings['allowed_values'] as $item) {
      $bundles[] = $item['vocabulary'];
    }
    return $bundles;
  }

}

Classes

Namesort descending Description
CerTaxonomyTermReferenceField @file Contains the CER plugin for Taxonomy Term Reference fields.