feat: add Publicities page with comprehensive management functionalities including list/calendar views and CRUD operations.

This commit is contained in:
Michael committed 2026-01-05 17:10:10 +01:00
1 parent 18c51959af
commit eb3fb119ee
2 files changed
+26 -12

No files matched your search

+13 -2
View File
@@ -1,4 +1,5 @@
import { Switch, Route } from "wouter";
import { useEffect } from "react";
import { Switch, Route, useLocation } from "wouter";
import { useAuthUnified } from "@/hooks/useAuthUnified";
import { useScreenSize } from "@/hooks/use-screen-size";
import NotFound from "@/pages/not-found";
@@ -42,6 +43,15 @@ import MobileDlcPage from "@/pages/mobile/DlcPage";
import MobileSavPage from "@/pages/mobile/SavPage";
import MobileAvoirsPage from "@/pages/mobile/AvoirsPage";
// Helper component to handle redirection
const RedirectToAuth = () => {
const [, setLocation] = useLocation();
useEffect(() => {
setLocation("/auth");
}, [setLocation]);
return <AuthPage />;
};
function RouterProduction() {
const { isAuthenticated, isLoading, user, environment, error } = useAuthUnified();
const { isMobile } = useScreenSize();
@@ -86,7 +96,8 @@ function RouterProduction() {
<Switch>
<Route path="/auth" component={AuthPage} />
<Route path="/" component={AuthPage} />
<Route component={NotFound} />
{/* Redirect all other routes to auth */}
<Route component={RedirectToAuth} />
</Switch>
);
}