-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdashboard.php
More file actions
90 lines (83 loc) · 3.05 KB
/
Copy pathdashboard.php
File metadata and controls
90 lines (83 loc) · 3.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
<?php
require_once 'config.php';
requireLogin();
$db = getDB();
$tab = isset($_GET['tab']) ? $_GET['tab'] : 'turmas';
?>
<!DOCTYPE html>
<html lang="pt-BR">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>EcoDesafio Escolar - Painel Administrativo</title>
<link rel="stylesheet" href="assets/css/style.css">
<link rel="icon" type="image/x-icon" href="assets/images/logo_icone.svg">
</head>
<body class="bg-mint">
<div class="container">
<!-- Logo -->
<div class="logo-container">
<div class="logo">
<!--<span class="logo-icon">🌱</span>
<span class="logo-text">EcoDesafio</span>-->
<img src="assets/images/logo_tp.png" alt="EcoDesafio Escolar Logo" class="logo-image">
</div>
</div>
<!-- Header -->
<div class="dashboard-header">
<div class="dashboard-title">
<div>
<h1>Painel Administrativo</h1>
<p>Gerencie todo o sistema</p>
</div>
</div>
<div class="dashboard-actions">
<a href="index.php" class="btn btn-primary btn-sm">Ver Ranking</a>
<a href="logout.php" class="btn btn-secondary btn-sm">Sair</a>
</div>
</div>
<!-- Tabs -->
<div class="tabs">
<a href="dashboard.php?tab=turmas" class="tab tab-turmas <?php echo $tab === 'turmas' ? 'active' : ''; ?>">
📚 Turmas
</a>
<a href="dashboard.php?tab=atividades" class="tab tab-atividades <?php echo $tab === 'atividades' ? 'active' : ''; ?>">
✅ Atividades
</a>
<a href="dashboard.php?tab=registros" class="tab tab-registros <?php echo $tab === 'registros' ? 'active' : ''; ?>">
📋 Registros
</a>
<?php if (isAdmin()): ?>
<a href="dashboard.php?tab=usuarios" class="tab tab-usuarios <?php echo $tab === 'usuarios' ? 'active' : ''; ?>">
👥 Usuários
</a>
<?php endif; ?>
</div>
<!-- Content -->
<div class="content">
<?php
switch ($tab) {
case 'turmas':
include 'sections/turmas.php';
break;
case 'atividades':
include 'sections/atividades.php';
break;
case 'registros':
include 'sections/registros.php';
break;
case 'usuarios':
if (isAdmin()) {
include 'sections/usuarios.php';
}
break;
default:
include 'sections/turmas.php';
}
?>
</div>
</div>
<?php include 'sections/footer.php'; ?>
<script src="assets/js/script.v2.js?v=<?php echo filemtime('assets/js/script.v2.js'); ?>"></script>
</body>
</html>