The entity list builder doesn't provide routes. For this you have another annotation entry:
* "route_provider" = {
* "html" = "Drupal\Core\Entity\Routing\AdminHtmlRouteProvider",
Which by default points at DefaultHtmlRouteProvider
or in this case at a subclass changing some routes to admin routes.
You can do the same, extend DefaultHtmlRouteProvider and override getCollectionRoute():
protected function getCollectionRoute(EntityTypeInterface $entity_type) {
// If the entity type does not provide an admin permission, there is no way
// to control access, so we cannot provide a route in a sensible way.
if ($entity_type->hasLinkTemplate('collection') && $entity_type->hasListBuilderClass() && ($admin_permission = $entity_type->getAdminPermission())) {
/** @var \Drupal\Core\StringTranslation\TranslatableMarkup $label */
$label = $entity_type->getCollectionLabel();
$route = new Route($entity_type->getLinkTemplate('collection'));
$route
->addDefaults([
'_entity_list' => $entity_type->id(),
'_title' => $label->getUntranslatedString(),
'_title_arguments' => $label->getArguments(),
'_title_context' => $label->getOption('context'),
])
->setRequirement('_permission', $admin_permission);
return $route;
}
}
For details how to add a custom access() method to a route see https://www.drupal.org/docs/8/api/routing-system/access-checking-on-routes