Skip to content

Commit 23a9ab5

Browse files
committed
Updates for Wipro (PS-257)
1 parent fc9b219 commit 23a9ab5

File tree

1 file changed

+15
-2
lines changed
  • src/shared/components/tc-communities/Header

1 file changed

+15
-2
lines changed

src/shared/components/tc-communities/Header/index.jsx

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,18 +72,30 @@ function Header(props) {
7272
}
7373

7474
let userSubMenu;
75+
7576
if (profile) {
77+
console.log('PROFILE');
78+
console.log(JSON.stringify(profile, null, 4));
79+
let profileLink = `${meta ? _.replace(BASE_URL, 'www', meta.subdomains[0]) : BASE_URL}/members/${normalizedProfile.handle}`;
80+
let paymentsLink = `${config.URL.COMMUNITY}/PactsMemberServlet?module=PaymentHistory&full_list=false`;
81+
82+
// Handle Wipro specific links (PS-257)
83+
if (profile && profile.email && profile.email.includes('@wipro.com')) {
84+
profileLink = 'https://topgear-app.wipro.com/user-details';
85+
paymentsLink = 'https://topgear-app.wipro.com/my_payments';
86+
}
87+
7688
userSubMenu = {
7789
title: 'User',
7890
items: [{
7991
enforceA: true,
8092
icon: <IconNavProfile />,
81-
link: `${meta ? _.replace(BASE_URL, 'www', meta.subdomains[0]) : BASE_URL}/members/${normalizedProfile.handle}`,
93+
link: profileLink,
8294
title: 'My Profile',
8395
}, {
8496
openNewTab: true,
8597
icon: <IconNavWallet />,
86-
link: `${config.URL.COMMUNITY}/PactsMemberServlet?module=PaymentHistory&full_list=false`,
98+
link: paymentsLink,
8799
title: 'Payments',
88100
}, {
89101
icon: <IconNavSettings />,
@@ -385,6 +397,7 @@ Header.propTypes = {
385397
photoURL: PT.string,
386398
groups: PT.any,
387399
handle: PT.string,
400+
email: PT.string,
388401
}),
389402
theme: PT.shape().isRequired,
390403
logoutRedirect: PT.string,

0 commit comments

Comments
 (0)