You are here

public function ScheduledTransitionsListBuilder::buildOperations in Scheduled Transitions 8

Same name and namespace in other branches
  1. 2.x src/ScheduledTransitionsListBuilder.php \Drupal\scheduled_transitions\ScheduledTransitionsListBuilder::buildOperations()

Builds a renderable list of operation links for the entity.

Parameters

\Drupal\Core\Entity\EntityInterface $entity: The entity on which the linked operations will be performed.

Return value

array A renderable array of operation links.

Overrides EntityListBuilder::buildOperations

See also

\Drupal\Core\Entity\EntityListBuilder::buildRow()

File

src/ScheduledTransitionsListBuilder.php, line 135

Class

ScheduledTransitionsListBuilder
Scheduled transition list builder.

Namespace

Drupal\scheduled_transitions

Code

public function buildOperations(EntityInterface $entity) {
  $build = parent::buildOperations($entity);

  // Add access cacheability, remove after @todo in getDefaultOperations is
  // completed.
  $build['#cache']['contexts'][] = 'user.permissions';
  return $build;
}