From 3077ae7e1bdbc02a088fbc6593fb7c6c96065bd4 Mon Sep 17 00:00:00 2001 From: Stas Vilchik Date: Mon, 12 Dec 2016 16:24:56 +0100 Subject: support old project permalinks --- server/sonar-web/src/main/js/app/utils/startReactApp.js | 4 ++++ server/sonar-web/src/main/js/apps/overview/routes.js | 7 +++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/server/sonar-web/src/main/js/app/utils/startReactApp.js b/server/sonar-web/src/main/js/app/utils/startReactApp.js index 3e1bba4f6ff..e92ba5d8996 100644 --- a/server/sonar-web/src/main/js/app/utils/startReactApp.js +++ b/server/sonar-web/src/main/js/app/utils/startReactApp.js @@ -70,6 +70,10 @@ const startReactApp = () => { render(( + { + replace({ pathname: '/dashboard', query: { id: nextState.params.key } }); + }}/> + diff --git a/server/sonar-web/src/main/js/apps/overview/routes.js b/server/sonar-web/src/main/js/apps/overview/routes.js index 6fac11a62ab..c28123a7a38 100644 --- a/server/sonar-web/src/main/js/apps/overview/routes.js +++ b/server/sonar-web/src/main/js/apps/overview/routes.js @@ -18,11 +18,10 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ import React from 'react'; -import { IndexRoute, Route } from 'react-router'; +import { IndexRoute, Redirect } from 'react-router'; import AppContainer from './components/AppContainer'; export default [ - , - , - + , + ]; -- cgit v1.2.3