Skip to content
Snippets Groups Projects
Commit 882f3573 authored by xiaohua guan's avatar xiaohua guan Committed by Yas Naoi
Browse files

Issue #3363744 by Xiaohua Guan, yas: Add a menu link to display the module permission list

parent 4084fea5
No related branches found
No related tags found
No related merge requests found
......@@ -124,12 +124,25 @@ class CloudMenuLinks extends DeriverBase implements ContainerDeriverInterface {
$id = "cloud.admin.menu.users";
$links[$id] = $base_plugin_definition;
$links[$id]['title'] = $this->t('@title', ['@title' => $title]);
$links[$id]['route_name'] = "entity.user.collection";
$links[$id]['route_name'] = 'entity.user.collection';
$links[$id]['menu_name'] = 'cloud.admin.menu.users';
$links[$id]['parent'] = 'cloud.admin.menu';
$links[$id]['weight'] = 20;
}
// Add permissions link under manage menu,
// if the "Module Permissions" module is enabled.
if ($this->moduleHandler->moduleExists('module_permissions')) {
$title = "Permissions";
$id = "cloud.admin.menu.permissions";
$links[$id] = $base_plugin_definition;
$links[$id]['title'] = $this->t('@title', ['@title' => $title]);
$links[$id]['route_name'] = 'user.admin_permissions';
$links[$id]['menu_name'] = 'cloud.admin.menu.permissions';
$links[$id]['parent'] = 'cloud.admin.menu';
$links[$id]['weight'] = 30;
}
return $links;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment