diff --git a/lib/components/menu.dart b/lib/components/menu.dart index 4e72586..cb63be0 100644 --- a/lib/components/menu.dart +++ b/lib/components/menu.dart @@ -71,13 +71,13 @@ class _MenuState extends State { } }); } else if (index == 1) { - html.window.history.pushState(null, '', '/products'); + html.window.history.pushState(null, '', '/#/products'); _selectedWidget = const Products(); } else if (index == 2) { html.window.history.pushState(null, '', ''); _selectedWidget = const Home(); } else if (index == 3) { - html.window.history.pushState(null, '', '/cart'); + html.window.history.pushState(null, '', '/#/cart'); _selectedWidget = const Cart(); } else if (index == 4) { checkSessionExist().then((isLoggedIn) { diff --git a/lib/utils/navigation_auth.dart b/lib/utils/navigation_auth.dart index d724073..affb02e 100644 --- a/lib/utils/navigation_auth.dart +++ b/lib/utils/navigation_auth.dart @@ -20,7 +20,7 @@ class NavigationAuth extends StatelessWidget { if (data) { return route; } else { - html.window.history.pushState(null, '', '/login'); + html.window.history.pushState(null, '', '/#/login'); return const Login(); } } else {