Initial commit: MSP Monitor Dashboard

- Next.js 14 frontend with dark cyan/navy theme
- tRPC API with Prisma ORM
- MeshCentral, LibreNMS, Headwind MDM integrations
- Multi-tenant architecture
- Alert system with email/SMS/webhook notifications
- Docker Compose deployment
- Complete documentation
This commit is contained in:
MSP Monitor
2026-01-21 19:29:20 +00:00
commit f4491757d9
57 changed files with 10503 additions and 0 deletions

View File

@@ -0,0 +1,40 @@
'use client'
import { useState, useEffect } from 'react'
import Sidebar from '@/components/layout/Sidebar'
import Header from '@/components/layout/Header'
export default function DashboardLayout({
children,
}: {
children: React.ReactNode
}) {
const [alertasActivas, setAlertasActivas] = useState(0)
const [user, setUser] = useState({
nombre: 'Admin',
email: 'admin@example.com',
rol: 'SUPER_ADMIN',
})
useEffect(() => {
// TODO: Cargar alertas activas desde API
// TODO: Cargar usuario desde sesion
}, [])
const handleLogout = async () => {
// TODO: Implementar logout
window.location.href = '/login'
}
return (
<div className="flex h-screen bg-dark-500">
<Sidebar alertasActivas={alertasActivas} />
<div className="flex-1 flex flex-col overflow-hidden">
<Header user={user} onLogout={handleLogout} />
<main className="flex-1 overflow-y-auto p-6">
{children}
</main>
</div>
</div>
)
}