Skip to content

Commit 912508f

Browse files
Ludo HartzemaLOBsTerr
authored andcommitted
Grant [generate:entity:content] correct view permissions for revisions (#3932) (#3933)
1 parent 37730ce commit 912508f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

templates/module/src/entity-content-route-provider.php.twig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ class {{ entity_class }}HtmlRouteProvider extends AdminHtmlRouteProvider {% endb
8080
'_title' => "{$entity_type->getLabel()} revisions",
8181
'_controller' => '\Drupal\{{ module }}\Controller\{{ entity_class }}Controller::revisionOverview',
8282
])
83-
->setRequirement('_permission', 'access {{ label|lower }} revisions')
83+
->setRequirement('_permission', 'view all {{ label|lower }} revisions')
8484
->setOption('_admin_route', TRUE);
8585

8686
return $route;
@@ -104,7 +104,7 @@ class {{ entity_class }}HtmlRouteProvider extends AdminHtmlRouteProvider {% endb
104104
'_controller' => '\Drupal\{{ module }}\Controller\{{ entity_class }}Controller::revisionShow',
105105
'_title_callback' => '\Drupal\{{ module }}\Controller\{{ entity_class }}Controller::revisionPageTitle',
106106
])
107-
->setRequirement('_permission', 'access {{ label|lower }} revisions')
107+
->setRequirement('_permission', 'view all {{ label|lower }} revisions')
108108
->setOption('_admin_route', TRUE);
109109

110110
return $route;

0 commit comments

Comments
 (0)