From f2d9f0001302c548216b542867fa0ddf3ed483cc Mon Sep 17 00:00:00 2001 From: Erik Ritter Date: Wed, 2 Dec 2020 09:14:23 -0800 Subject: [PATCH] feat: allow user to view their profile again (#11816) --- superset-frontend/src/components/Menu/Menu.tsx | 12 ++++++++++-- superset/templates/appbuilder/navbar_right.html | 3 ++- superset/views/base.py | 3 +++ 3 files changed, 15 insertions(+), 3 deletions(-) diff --git a/superset-frontend/src/components/Menu/Menu.tsx b/superset-frontend/src/components/Menu/Menu.tsx index bce2e2307e..28cb532ee0 100644 --- a/superset-frontend/src/components/Menu/Menu.tsx +++ b/superset-frontend/src/components/Menu/Menu.tsx @@ -46,6 +46,7 @@ interface NavBarProps { user_info_url: string; user_login_url: string; user_logout_url: string; + user_profile_url: string | null; locale: string; } @@ -195,8 +196,15 @@ export function Menu({ {!navbarRight.user_is_anonymous && [ , - - {t('Profile')} + {navbarRight.user_profile_url && ( + + + {t('Profile')} + + + )} + + {t('Info')} {t('Logout')} diff --git a/superset/templates/appbuilder/navbar_right.html b/superset/templates/appbuilder/navbar_right.html index 881db00b79..334e7ea2ad 100644 --- a/superset/templates/appbuilder/navbar_right.html +++ b/superset/templates/appbuilder/navbar_right.html @@ -106,7 +106,8 @@