Add server monitoring and database backup pages
New sidebar sections wired to the backend's new admin APIs: - Monitoring: live request/error-rate/latency stats plus a recent-requests table, polling every 8s. - Backups: create/list/download database backups (auth'd blob download since the endpoint requires a Bearer token, not a plain link).
This commit is contained in:
@@ -2,7 +2,16 @@
|
||||
|
||||
import Link from "next/link";
|
||||
import { usePathname, useRouter } from "next/navigation";
|
||||
import { LayoutGrid, ListTree, MessageCircleQuestion, LogOut, Heart, UserCheck } from "lucide-react";
|
||||
import {
|
||||
LayoutGrid,
|
||||
ListTree,
|
||||
MessageCircleQuestion,
|
||||
LogOut,
|
||||
Heart,
|
||||
UserCheck,
|
||||
Activity,
|
||||
Database,
|
||||
} from "lucide-react";
|
||||
import { cn } from "@/lib/utils";
|
||||
import { useAuth } from "@/lib/auth-context";
|
||||
|
||||
@@ -11,6 +20,8 @@ const navItems = [
|
||||
{ href: "/users", label: "کاربران در انتظار تایید", icon: UserCheck },
|
||||
{ href: "/categories", label: "دستهبندیها و گزینهها", icon: ListTree },
|
||||
{ href: "/questions", label: "سوالات پروفایل", icon: MessageCircleQuestion },
|
||||
{ href: "/monitoring", label: "مانیتورینگ سرور", icon: Activity },
|
||||
{ href: "/backups", label: "بکآپ دیتابیس", icon: Database },
|
||||
];
|
||||
|
||||
export function Sidebar() {
|
||||
|
||||
Reference in New Issue
Block a user