Skip to content

Commit 4780b18

Browse files
authored
Merge pull request #4123 from maxceem/issue-4069
fix: open reports tab after searching
2 parents 7a0a087 + d46b8d1 commit 4780b18

File tree

2 files changed

+15
-5
lines changed

2 files changed

+15
-5
lines changed
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
/**
2+
* Reports pages tool bar
3+
*/
4+
import React from 'react'
5+
import SectionTopBar from '../../../components/TopBar/SectionToolBar'
6+
7+
const ReportsToolBar = () => (
8+
<SectionTopBar title="Reports" menu={[]} />
9+
)
10+
11+
export default ReportsToolBar

src/routes/reports/routes.jsx

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,10 @@ import React from 'react'
55
import { Route } from 'react-router-dom'
66
import { renderApp } from '../../components/App/App'
77
import TopBarContainer from '../../components/TopBar/TopBarContainer'
8-
import ProjectsToolBar from '../../components/TopBar/ProjectsToolBar'
8+
import ReportsToolBar from './components/ReportsToolBar'
99
import { requiresAuthentication } from '../../components/AuthenticatedComponent'
1010
import UserReportsContainer from './containers/UserReportsContainer'
1111
const UserReportsContainerWithAuth = requiresAuthentication(UserReportsContainer)
12-
export default [
13-
<Route key="reports" exact path="/reports" render={renderApp(<TopBarContainer toolbar={ProjectsToolBar} />, <UserReportsContainerWithAuth />)} />,
14-
15-
]
12+
export default (
13+
<Route path="/reports" exact render={renderApp(<TopBarContainer toolbar={ReportsToolBar} />, <UserReportsContainerWithAuth />)} />
14+
)

0 commit comments

Comments
 (0)