mirror of
https://github.com/chillpadclub/bedolaga-cabinet.git
synced 2026-07-30 02:23:47 +00:00
Update App.tsx
This commit is contained in:
@@ -25,6 +25,7 @@ import AdminTariffs from './pages/AdminTariffs'
|
|||||||
import AdminServers from './pages/AdminServers'
|
import AdminServers from './pages/AdminServers'
|
||||||
import AdminPanel from './pages/AdminPanel'
|
import AdminPanel from './pages/AdminPanel'
|
||||||
import AdminDashboard from './pages/AdminDashboard'
|
import AdminDashboard from './pages/AdminDashboard'
|
||||||
|
import AdminBroadcasts from './pages/AdminBroadcasts'
|
||||||
|
|
||||||
function ProtectedRoute({ children }: { children: React.ReactNode }) {
|
function ProtectedRoute({ children }: { children: React.ReactNode }) {
|
||||||
const { isAuthenticated, isLoading } = useAuthStore()
|
const { isAuthenticated, isLoading } = useAuthStore()
|
||||||
@@ -217,6 +218,14 @@ function App() {
|
|||||||
</AdminRoute>
|
</AdminRoute>
|
||||||
}
|
}
|
||||||
/>
|
/>
|
||||||
|
<Route
|
||||||
|
path="/admin/broadcasts"
|
||||||
|
element={
|
||||||
|
<AdminRoute>
|
||||||
|
<AdminBroadcasts />
|
||||||
|
</AdminRoute>
|
||||||
|
}
|
||||||
|
/>
|
||||||
|
|
||||||
{/* Catch all */}
|
{/* Catch all */}
|
||||||
<Route path="*" element={<Navigate to="/" replace />} />
|
<Route path="*" element={<Navigate to="/" replace />} />
|
||||||
|
|||||||
Reference in New Issue
Block a user