From b62e29ba9cd6183551266da05b9b602a4415d738 Mon Sep 17 00:00:00 2001 From: Christopher Speller Date: Thu, 24 Mar 2016 11:05:13 -0400 Subject: Moving all links and redirects to react-router --- .../admin_console/admin_navbar_dropdown.jsx | 29 +++------------------- webapp/components/admin_console/user_item.jsx | 5 ++-- 2 files changed, 6 insertions(+), 28 deletions(-) (limited to 'webapp/components/admin_console') diff --git a/webapp/components/admin_console/admin_navbar_dropdown.jsx b/webapp/components/admin_console/admin_navbar_dropdown.jsx index 56b78448a..9644a2e7f 100644 --- a/webapp/components/admin_console/admin_navbar_dropdown.jsx +++ b/webapp/components/admin_console/admin_navbar_dropdown.jsx @@ -63,8 +63,8 @@ export default class AdminNavbarDropdown extends React.Component { role='menu' >
  • - - +
  • @@ -83,29 +83,6 @@ export default class AdminNavbarDropdown extends React.Component { />
  • -
  • -
  • - - - -
  • -
  • - - - -
  • diff --git a/webapp/components/admin_console/user_item.jsx b/webapp/components/admin_console/user_item.jsx index c6498eafc..91f567d4d 100644 --- a/webapp/components/admin_console/user_item.jsx +++ b/webapp/components/admin_console/user_item.jsx @@ -10,6 +10,7 @@ import TeamStore from 'stores/team_store.jsx'; import {FormattedMessage} from 'react-intl'; import React from 'react'; +import {browserHistory} from 'react-router'; export default class UserItem extends React.Component { constructor(props) { @@ -158,9 +159,9 @@ export default class UserItem extends React.Component { const teamUrl = TeamStore.getCurrentTeamUrl(); if (teamUrl) { - window.location.href = teamUrl; + browserHistory.push(teamUrl); } else { - window.location.href = '/'; + browserHistory.push('/'); } }, (err) => { -- cgit v1.2.3-1-g7c22 From d6a6668a39db2f78d59919686c5d7b901888da36 Mon Sep 17 00:00:00 2001 From: Christopher Speller Date: Thu, 24 Mar 2016 11:27:05 -0400 Subject: Modifying login not to display until it has finished checking. Caused admin console to redirect to town-square. Will be changed after user model flip. --- webapp/components/admin_console/admin_navbar_dropdown.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'webapp/components/admin_console') diff --git a/webapp/components/admin_console/admin_navbar_dropdown.jsx b/webapp/components/admin_console/admin_navbar_dropdown.jsx index 9644a2e7f..527f97959 100644 --- a/webapp/components/admin_console/admin_navbar_dropdown.jsx +++ b/webapp/components/admin_console/admin_navbar_dropdown.jsx @@ -64,7 +64,7 @@ export default class AdminNavbarDropdown extends React.Component { >