function RevisionLinkDelete::getUrlInfo
Same name in other branches
- 9 core/modules/node/src/Plugin/views/field/RevisionLinkDelete.php \Drupal\node\Plugin\views\field\RevisionLinkDelete::getUrlInfo()
- 8.9.x core/modules/node/src/Plugin/views/field/RevisionLinkDelete.php \Drupal\node\Plugin\views\field\RevisionLinkDelete::getUrlInfo()
- 10 core/modules/node/src/Plugin/views/field/RevisionLinkDelete.php \Drupal\node\Plugin\views\field\RevisionLinkDelete::getUrlInfo()
Overrides RevisionLink::getUrlInfo
File
-
core/
modules/ node/ src/ Plugin/ views/ field/ RevisionLinkDelete.php, line 20
Class
- RevisionLinkDelete
- Field handler to present link to delete a node revision.
Namespace
Drupal\node\Plugin\views\fieldCode
protected function getUrlInfo(ResultRow $row) {
/** @var \Drupal\node\NodeInterface $node */
$node = $this->getEntity($row);
if (!$node) {
return NULL;
}
return Url::fromRoute('node.revision_delete_confirm', [
'node' => $node->id(),
'node_revision' => $node->getRevisionId(),
]);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.