revise backend

This commit is contained in:
Michal Sedlák
2026-10-18 15:55:34 +02:00
parent dc452059f3
commit 99b1c96f4b
23 changed files with 681 additions and 720 deletions
+3 -12
View File
@@ -1,16 +1,8 @@
<?php
// Include this at the top to see potential errors
// Comment out in production
ini_set('display_errors', 1);
error_reporting(E_ALL);
require_once __DIR__ . '/../../includes/auth.php';
requireLogin('../../index.php');
session_start();
if (empty($_SESSION['admin']) || $_SESSION['admin'] !== true) {
session_destroy();
header("location: ../../index.php");
exit();
}
requirePermission('admin', 'You do not have permission to view server statistics.');
require_once __DIR__ . '/../../config/config.php';
require_once __DIR__ . '/../../includes/workspace.php';
@@ -90,7 +82,6 @@ $monitors = [
'class' => 'server-page',
]); ?>
<div class="content-toolbar"><p>Live statistics · refreshes every 5 seconds</p><span class="badge bg-light text-dark"><i class="ui-icon icon-clock" aria-hidden="true"></i> <?= htmlspecialchars($systemData['lastUpdate']) ?></span></div>
<div class="stats-grid">
<?php foreach ($monitors as $monitor): ?>