From 38e9f90fe88111272ef78867377371208763bf07 Mon Sep 17 00:00:00 2001 From: "Luiz R. Rodrigues" Date: Tue, 1 Jun 2021 02:33:36 -0300 Subject: [PATCH 1/4] TopGear : Redirect home to topgear-app --- src/shared/routes/Communities/Wipro/Routes.jsx | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/src/shared/routes/Communities/Wipro/Routes.jsx b/src/shared/routes/Communities/Wipro/Routes.jsx index 41a7ab889d..eb51249a56 100644 --- a/src/shared/routes/Communities/Wipro/Routes.jsx +++ b/src/shared/routes/Communities/Wipro/Routes.jsx @@ -5,7 +5,7 @@ import ChallengeDetails from 'routes/ChallengeDetails'; import ChallengeListing from 'routes/Communities/ChallengeListing'; import ChallengeListingBanner from 'components/tc-communities/communities/wipro/ChallengeListingBanner'; -import ContentfulRoute from 'components/Contentful/Route'; +// import ContentfulRoute from 'components/Contentful/Route'; import Header from 'containers/tc-communities/Header'; import LeaderboardBanner from 'components/tc-communities/communities/wipro/LeaderboardBanner'; import PT from 'prop-types'; @@ -20,7 +20,7 @@ import Viewport from 'components/Contentful/Viewport'; import theme from 'components/tc-communities/communities/wipro/theme'; import { ThemeProvider } from 'react-css-super-themr'; import { Route, Switch } from 'react-router-dom'; -import { config } from 'topcoder-react-utils'; +import { config, isomorphy } from 'topcoder-react-utils'; import Leaderboard from '../Leaderboard'; @@ -115,11 +115,22 @@ export default function Wipro({ base, meta }) { exact path={`${base}/leaderboard`} /> + {/* + */} + { + if (isomorphy.isClientSide()) { + window.location = config.URL.TOPGEAR; + } + return null; + }} + /> Date: Tue, 1 Jun 2021 02:34:13 -0300 Subject: [PATCH 2/4] TopGear : Update login retUrl to topgear-app --- src/shared/containers/tc-communities/Loader.jsx | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/shared/containers/tc-communities/Loader.jsx b/src/shared/containers/tc-communities/Loader.jsx index c05eb4e69b..e0c754d5de 100644 --- a/src/shared/containers/tc-communities/Loader.jsx +++ b/src/shared/containers/tc-communities/Loader.jsx @@ -51,11 +51,10 @@ class Loader extends React.Component { * clear, what exactly do we need to support it in general. */ if ((communityId === 'wipro' || communityId === 'comcast') && !visitorGroups) { const returnUrl = encodeURIComponent(window.location.href); - let subpath = 'member'; if (communityId === 'wipro') { - subpath = 'sso-login/'; + window.location = `${config.URL.AUTH}/?retUrl=${config.URL.TOPGEAR}`; } - window.location = `${config.URL.AUTH}/${subpath}?retUrl=${returnUrl}&utm_source=${communityId}`; + window.location = `${config.URL.AUTH}/member?retUrl=${returnUrl}&utm_source=${communityId}`; } } From a67e3755b0c0c99184be21d42c7d83553521421f Mon Sep 17 00:00:00 2001 From: "Luiz R. Rodrigues" Date: Tue, 1 Jun 2021 02:34:38 -0300 Subject: [PATCH 3/4] TopGear : Remove TopGear Operations and FAQ --- src/server/tc-communities/wipro/metadata.json | 7 ------- 1 file changed, 7 deletions(-) diff --git a/src/server/tc-communities/wipro/metadata.json b/src/server/tc-communities/wipro/metadata.json index 40cd8f5975..4ba1897f95 100644 --- a/src/server/tc-communities/wipro/metadata.json +++ b/src/server/tc-communities/wipro/metadata.json @@ -29,10 +29,6 @@ "menuItems": [ { "title": "Home", - "url": "/" - }, { - "title": "TopGear Operations", - "openNewTab": true, "url": "https://topgear-app.wipro.com" }, { "title": "Challenges", @@ -40,9 +36,6 @@ }, { "title": "Leaderboard", "url": "/leaderboard" - }, { - "title": "FAQ", - "url": "https://topgear-app.wipro.com/faq-categories" } ], "newsFeed": "http://www.topcoder.com/feed", From a6a590a11cdd82fdccc1a2860cac67ec8ac0e916 Mon Sep 17 00:00:00 2001 From: "Luiz R. Rodrigues" Date: Tue, 1 Jun 2021 02:35:37 -0300 Subject: [PATCH 4/4] ci: Deploy topgear-app to Dev and Stag env --- .circleci/config.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 66156c3f8c..2477cf3da4 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -333,6 +333,7 @@ workflows: branches: only: - develop + - topgear-app # This is alternate dev env for parallel testing - deployTest: context : org-global @@ -361,6 +362,7 @@ workflows: branches: only: - develop + - topgear-app # Production builds are exectuted # when PR is merged to the master # Don't change anything in this configuration