From 812962ace00d4c3c19698233c1c01db01dbc4a3e Mon Sep 17 00:00:00 2001 From: Yinyin Liu Date: Thu, 26 Mar 2026 10:31:32 +0100 Subject: [PATCH] sodistore home as default loggin page --- typescript/frontend-marios2/src/App.tsx | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/typescript/frontend-marios2/src/App.tsx b/typescript/frontend-marios2/src/App.tsx index ac990058d..2c78cc770 100644 --- a/typescript/frontend-marios2/src/App.tsx +++ b/typescript/frontend-marios2/src/App.tsx @@ -34,6 +34,11 @@ function App() { const searchParams = new URLSearchParams(location.search); const username = searchParams.get('username'); const { + accessToSalimax, + accessToSodiohome, + accessToSodistore, + accessToSodistoreGrid, + accessToSodistorePro, setAccessToSalimax, setAccessToSalidomo, setAccessToSodiohome, @@ -42,6 +47,18 @@ function App() { setAccessToSodistorePro } = useContext(ProductIdContext); + const defaultRoute = accessToSodiohome + ? routes.sodiohome_installations + : accessToSodistorePro + ? routes.sodistorepro_installations + : accessToSodistoreGrid + ? routes.sodistoregrid_installations + : accessToSodistore + ? routes.sodistore_installations + : accessToSalimax + ? routes.installations + : routes.salidomo_installations; + const detectBrowserLanguage = (): string => { const browserLang = navigator.language?.toLowerCase() || ''; if (browserLang.startsWith('de')) return 'de'; @@ -186,11 +203,11 @@ function App() { } + element={} > } + element={} > } /> } + element={} > }>