You are here

function ds_test_get_tag_name in Display Suite 8.4

Same name and namespace in other branches
  1. 8.2 tests/modules/ds_test/ds_test.module \ds_test_get_tag_name()
  2. 8.3 tests/modules/ds_test/ds_test.module \ds_test_get_tag_name()
  3. 7.2 tests/ds_test.module \ds_test_get_tag_name()
  4. 7 tests/ds_test.module \ds_test_get_tag_name()

Helper function to return the tag name basid on tid.

1 string reference to 'ds_test_get_tag_name'
views.view.ds-testing.yml in tests/modules/ds_test/test_views/views.view.ds-testing.yml
tests/modules/ds_test/test_views/views.view.ds-testing.yml

File

tests/modules/ds_test/ds_test.module, line 27
Display Suite test module.

Code

function ds_test_get_tag_name($raw_value, $object) {
  $entity_manager = \Drupal::entityTypeManager();
  $term = $entity_manager
    ->getStorage('taxonomy_term')
    ->load($raw_value);
  return $term->name->value;
}