EntityListBuilder::buildOperations

public EntityListBuilder::buildOperations(EntityInterface $entity)

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.

See also

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

File

core/lib/Drupal/Core/Entity/EntityListBuilder.php, line 200

Class

EntityListBuilder
Defines a generic implementation to build a listing of entities.

Namespace

Drupal\Core\Entity

Code

public function buildOperations(EntityInterface $entity) {
  $build = array(
    '#type' => 'operations',
    '#links' => $this->getOperations($entity),
  );

  return $build;
}
doc_Drupal
2016-10-29 09:06:51
Comments
Leave a Comment

Please login to continue.