You are here

public function FieldCollectionItemController::revisionPageTitle in Field collection 8

Same name and namespace in other branches
  1. 8.3 src/Controller/FieldCollectionItemController.php \Drupal\field_collection\Controller\FieldCollectionItemController::revisionPageTitle()

Page title callback for a field collection item revision.

Parameters

int $field_collection_item_revision: The field collection item revision ID.

Return value

string The page title.

1 string reference to 'FieldCollectionItemController::revisionPageTitle'
field_collection.routing.yml in ./field_collection.routing.yml
field_collection.routing.yml

File

src/Controller/FieldCollectionItemController.php, line 141

Class

FieldCollectionItemController
Returns responses for Field collection item routes.

Namespace

Drupal\field_collection\Controller

Code

public function revisionPageTitle($field_collection_item_revision) {
  $field_collection_item = $this
    ->entityTypeManager()
    ->getStorage('field_collection_item')
    ->loadRevision($field_collection_item_revision);
  return $this
    ->t('Revision %revision of %title', [
    '%revision' => $field_collection_item_revision,
    '%title' => $field_collection_item
      ->label(),
  ]);
}