<?php
declare(strict_types=1);
namespace App\Controllers;

use App\Core\Auth;
use App\Core\Controller;
use App\Core\Permission;
use App\Services\SecurityDashboardService;

final class SecurityDashboardController extends Controller
{
    public function index(): void
    {
        Auth::requireLogin();
        Permission::require('administration.permissions.view');
        $this->view('security/dashboard', [
            'pageTitle' => 'Supervision de la sécurité',
            'report' => (new SecurityDashboardService())->report(),
        ]);
    }
}
