[v9.3.x] Navigation: Prevent viewer role accessing dashboard creation, import and folder creation (#59009)
Navigation: Prevent viewer role accessing dashboard creation, import and folder creation (#58842)
hide pages related dashboard import create and folder creation for viewer role
(cherry picked from commit 14fbd44ac0)
Co-authored-by: Leo <108552997+lpskdl@users.noreply.github.com>
This commit is contained in:
co-authored by
Leo
parent
9521c90651
commit
90946b68a2
@@ -83,6 +83,7 @@ export function getAppRoutes(): RouteDescriptor[] {
|
||||
},
|
||||
{
|
||||
path: '/dashboard/new',
|
||||
roles: () => ['Editor', 'Admin'],
|
||||
pageClass: 'page-dashboard',
|
||||
routeName: DashboardRoutes.New,
|
||||
component: SafeDynamicImport(
|
||||
@@ -119,6 +120,7 @@ export function getAppRoutes(): RouteDescriptor[] {
|
||||
},
|
||||
{
|
||||
path: '/dashboard/import',
|
||||
roles: () => ['Editor', 'Admin'],
|
||||
component: SafeDynamicImport(
|
||||
() => import(/* webpackChunkName: "DashboardImport"*/ 'app/features/manage-dashboards/DashboardImportPage')
|
||||
),
|
||||
@@ -168,6 +170,7 @@ export function getAppRoutes(): RouteDescriptor[] {
|
||||
},
|
||||
{
|
||||
path: '/dashboards/folder/new',
|
||||
roles: () => ['Editor', 'Admin'],
|
||||
component: SafeDynamicImport(
|
||||
() => import(/* webpackChunkName: "NewDashboardsFolder"*/ 'app/features/folders/components/NewDashboardsFolder')
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user