Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Genesys PGR
Genesys Website
Commits
3d3ad005
Commit
3d3ad005
authored
Jan 07, 2019
by
Matija Obreza
Browse files
Navigation: included /, /admin, /dashboard in side navigation
parent
f5f03f55
Changes
3
Show whitespace changes
Inline
Side-by-side
src/ui/layout/AdminLayout.tsx
View file @
3d3ad005
...
...
@@ -7,6 +7,16 @@ import renderRoutes from 'ui/renderRoutes';
import
TopNavigation
from
'
./headers/v1/NavigationBar
'
;
const
ADMIN_MENUS
=
[
{
to
:
'
/
'
,
label
:
'
public.menu.home
'
,
inHeader
:
false
,
},
{
to
:
'
/admin
'
,
label
:
'
common.menu.Admin
'
,
inHeader
:
false
,
},
{
to
:
'
/admin/users
'
,
label
:
'
admin.menu.userManagement
'
,
...
...
src/ui/layout/DashboardLayout.tsx
View file @
3d3ad005
...
...
@@ -5,6 +5,16 @@ import renderRoutes from 'ui/renderRoutes';
import
TopNavigation
from
'
./headers/v1/NavigationBar
'
;
const
DASHBOARD_MENUS
=
[
{
to
:
'
/
'
,
label
:
'
public.menu.home
'
,
inHeader
:
false
,
},
{
to
:
'
/dashboard
'
,
label
:
'
common.menu.My Dashboard
'
,
inHeader
:
false
,
},
{
to
:
'
/dashboard/profile
'
,
label
:
'
user.dashboard.menu.profile
'
,
...
...
src/ui/layout/headers/v1/MenuBar.tsx
View file @
3d3ad005
...
...
@@ -28,6 +28,7 @@ class MenuBar extends React.Component<IMenuBarProps, any> {
private
renderMenu
=
(
path
:
any
)
=>
{
const
{
t
,
location
,
theme
}
=
this
.
props
;
// console.log(`P ${path.to} inHeader=${path.inHeader}`, path.inHeader !== undefined && ! path.inHeader);
return
(
path
.
subMenus
?
(
<
MenuItem
...
...
@@ -39,7 +40,7 @@ class MenuBar extends React.Component<IMenuBarProps, any> {
children
=
{
path
.
subMenus
.
map
(
this
.
renderSubMenu
)
}
theme
=
{
theme
}
/>
)
:
(
)
:
(
path
.
inHeader
!==
undefined
&&
!
path
.
inHeader
)
?
null
:
(
<
MenuItem
root
label
=
{
typeof
path
.
label
===
'
string
'
?
t
(
path
.
label
)
:
path
.
label
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment