Compare commits
6
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
62b0c9c02a | ||
|
|
a8af446f32 | ||
|
|
951253c559 | ||
|
|
43fc4ba775 | ||
|
|
7f54bb42f3 | ||
|
|
8f84260186 |
No files matched your search
+137
-123
@@ -1,33 +1,34 @@
|
||||
<?php
|
||||
|
||||
$superuser = array(
|
||||
'admin' =>
|
||||
array(
|
||||
$superuser = array (
|
||||
'admin' =>
|
||||
array (
|
||||
'password' => 'bBHofurUJWKzPE8Z:',
|
||||
'active' => true,
|
||||
),
|
||||
);
|
||||
|
||||
$serviceGroups = array(
|
||||
'Info' =>
|
||||
array(
|
||||
$serviceGroups = array (
|
||||
'Info' =>
|
||||
array (
|
||||
'label' => 'Home',
|
||||
'defaultOpen' => true,
|
||||
'services' =>
|
||||
array(
|
||||
'services' =>
|
||||
array (
|
||||
0 => 'home_info',
|
||||
1 => 'vergabe',
|
||||
2 => 'links',
|
||||
3 => 'einkaufsliste',
|
||||
4 => 'termine',
|
||||
5 => 'ticket_board',
|
||||
),
|
||||
),
|
||||
'Ausbildung' =>
|
||||
array(
|
||||
'Ausbildung' =>
|
||||
array (
|
||||
'label' => 'Ausbildung',
|
||||
'defaultOpen' => true,
|
||||
'services' =>
|
||||
array(
|
||||
'services' =>
|
||||
array (
|
||||
0 => 'print_static',
|
||||
1 => 'zeiterfassung',
|
||||
2 => 'berichte_arbeit_gen',
|
||||
@@ -36,12 +37,12 @@ $serviceGroups = array(
|
||||
5 => 'berufsschulberichte',
|
||||
),
|
||||
),
|
||||
'Logs' =>
|
||||
array(
|
||||
'Logs' =>
|
||||
array (
|
||||
'label' => 'Webserver',
|
||||
'defaultOpen' => false,
|
||||
'services' =>
|
||||
array(
|
||||
'services' =>
|
||||
array (
|
||||
0 => 'public_request_logs',
|
||||
1 => 'public_request_chart',
|
||||
2 => 'backend_request_logs',
|
||||
@@ -49,24 +50,25 @@ $serviceGroups = array(
|
||||
4 => 'personal_request_logs',
|
||||
),
|
||||
),
|
||||
'System' =>
|
||||
array(
|
||||
'System' =>
|
||||
array (
|
||||
'label' => 'Verwaltung',
|
||||
'defaultOpen' => false,
|
||||
'services' =>
|
||||
array(
|
||||
'services' =>
|
||||
array (
|
||||
0 => 'data_info',
|
||||
1 => 'services_control',
|
||||
2 => 'user_control',
|
||||
3 => 'variablen_control',
|
||||
4 => 'ticket_control',
|
||||
),
|
||||
),
|
||||
'Test' =>
|
||||
array(
|
||||
'Test' =>
|
||||
array (
|
||||
'label' => 'Dev / Test',
|
||||
'defaultOpen' => false,
|
||||
'services' =>
|
||||
array(
|
||||
'services' =>
|
||||
array (
|
||||
0 => 'api_tester',
|
||||
1 => 'weather_chart',
|
||||
2 => 'tabellen',
|
||||
@@ -75,335 +77,347 @@ $serviceGroups = array(
|
||||
),
|
||||
);
|
||||
|
||||
$services = array(
|
||||
'home_info' =>
|
||||
array(
|
||||
$services = array (
|
||||
'home_info' =>
|
||||
array (
|
||||
'name' => 'Home',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'vergabe' =>
|
||||
array(
|
||||
'vergabe' =>
|
||||
array (
|
||||
'name' => 'Vergabe',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'print_static' =>
|
||||
array(
|
||||
'print_static' =>
|
||||
array (
|
||||
'name' => 'Berichte Drucken',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'api_tester' =>
|
||||
array(
|
||||
'api_tester' =>
|
||||
array (
|
||||
'name' => 'API Testing',
|
||||
'active' => true,
|
||||
'adminOnly' => true,
|
||||
),
|
||||
'weather_chart' =>
|
||||
array(
|
||||
'weather_chart' =>
|
||||
array (
|
||||
'name' => 'Wetter Statistik',
|
||||
'active' => true,
|
||||
'adminOnly' => true,
|
||||
),
|
||||
'data_info' =>
|
||||
array(
|
||||
'data_info' =>
|
||||
array (
|
||||
'name' => 'Data Info',
|
||||
'active' => true,
|
||||
'adminOnly' => true,
|
||||
),
|
||||
'links' =>
|
||||
array(
|
||||
'links' =>
|
||||
array (
|
||||
'name' => 'Links',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'public_request_logs' =>
|
||||
array(
|
||||
'public_request_logs' =>
|
||||
array (
|
||||
'name' => 'Public Logs',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'public_request_chart' =>
|
||||
array(
|
||||
'public_request_chart' =>
|
||||
array (
|
||||
'name' => 'Public Statistik',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'backend_request_logs' =>
|
||||
array(
|
||||
'backend_request_logs' =>
|
||||
array (
|
||||
'name' => 'Backend Logs',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'backend_request_chart' =>
|
||||
array(
|
||||
'backend_request_chart' =>
|
||||
array (
|
||||
'name' => 'Backend Statistik',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'personal_request_logs' =>
|
||||
array(
|
||||
'personal_request_logs' =>
|
||||
array (
|
||||
'name' => 'Persönliche Logs',
|
||||
'active' => true,
|
||||
'adminOnly' => true,
|
||||
),
|
||||
'services_control' =>
|
||||
array(
|
||||
'services_control' =>
|
||||
array (
|
||||
'name' => 'Seiten',
|
||||
'active' => true,
|
||||
'adminOnly' => true,
|
||||
),
|
||||
'zeiterfassung' =>
|
||||
array(
|
||||
'zeiterfassung' =>
|
||||
array (
|
||||
'name' => 'Zeit Erfassung',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'berichte_arbeit_gen' =>
|
||||
array(
|
||||
'berichte_arbeit_gen' =>
|
||||
array (
|
||||
'name' => 'Berichte PDF',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'user_control' =>
|
||||
array(
|
||||
'user_control' =>
|
||||
array (
|
||||
'name' => 'Benutzer',
|
||||
'active' => true,
|
||||
'adminOnly' => true,
|
||||
),
|
||||
'variablen_control' =>
|
||||
array(
|
||||
'variablen_control' =>
|
||||
array (
|
||||
'name' => 'Variablen',
|
||||
'active' => true,
|
||||
'adminOnly' => true,
|
||||
),
|
||||
'tabellen' =>
|
||||
array(
|
||||
'tabellen' =>
|
||||
array (
|
||||
'name' => 'Tabellen',
|
||||
'active' => true,
|
||||
'adminOnly' => true,
|
||||
),
|
||||
'berichte' =>
|
||||
array(
|
||||
'berichte' =>
|
||||
array (
|
||||
'name' => 'Berichte Einsehen',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'domains' =>
|
||||
array(
|
||||
'domains' =>
|
||||
array (
|
||||
'name' => 'Domains',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'einkaufsliste' =>
|
||||
array(
|
||||
'einkaufsliste' =>
|
||||
array (
|
||||
'name' => 'Einkaufsliste',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'termine' =>
|
||||
array(
|
||||
'termine' =>
|
||||
array (
|
||||
'name' => 'Termine',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'firmenberichte' =>
|
||||
array(
|
||||
'firmenberichte' =>
|
||||
array (
|
||||
'name' => 'Firmenberichte',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'berufsschulberichte' =>
|
||||
array(
|
||||
'berufsschulberichte' =>
|
||||
array (
|
||||
'name' => 'Berufsschulberichte',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'ticket_board' =>
|
||||
array (
|
||||
'name' => 'Tickets / Ideen',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
'ticket_control' =>
|
||||
array (
|
||||
'name' => 'Tickets',
|
||||
'active' => true,
|
||||
'adminOnly' => false,
|
||||
),
|
||||
);
|
||||
|
||||
$linkGroups = array(
|
||||
'info' =>
|
||||
array(
|
||||
$linkGroups = array (
|
||||
'info' =>
|
||||
array (
|
||||
'label' => 'Informationen',
|
||||
'color' => '#3498db',
|
||||
'defaultOpen' => false,
|
||||
),
|
||||
'tools' =>
|
||||
array(
|
||||
'tools' =>
|
||||
array (
|
||||
'label' => 'IoT',
|
||||
'color' => '#2ecc71',
|
||||
'defaultOpen' => false,
|
||||
),
|
||||
'admin' =>
|
||||
array(
|
||||
'admin' =>
|
||||
array (
|
||||
'label' => 'Administration',
|
||||
'color' => '#e74c3c',
|
||||
'defaultOpen' => false,
|
||||
),
|
||||
'devices' =>
|
||||
array(
|
||||
'devices' =>
|
||||
array (
|
||||
'label' => 'Geräte',
|
||||
'color' => '#b7db33',
|
||||
'defaultOpen' => false,
|
||||
),
|
||||
);
|
||||
|
||||
$linkButtons = array(
|
||||
0 =>
|
||||
array(
|
||||
$linkButtons = array (
|
||||
0 =>
|
||||
array (
|
||||
'label' => 'Gitea',
|
||||
'url' => 'http://gitea.mrhossa.de',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'admin',
|
||||
),
|
||||
1 =>
|
||||
array(
|
||||
1 =>
|
||||
array (
|
||||
'label' => 'HAProxy',
|
||||
'url' => 'http://stats.mrhossa.de',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'admin',
|
||||
),
|
||||
2 =>
|
||||
array(
|
||||
2 =>
|
||||
array (
|
||||
'label' => 'Public',
|
||||
'url' => 'https://mrhossa.de',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'info',
|
||||
),
|
||||
3 =>
|
||||
array(
|
||||
3 =>
|
||||
array (
|
||||
'label' => 'NAS-1',
|
||||
'url' => 'http://nas-1.blackpi.ipv64.net',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'devices',
|
||||
),
|
||||
4 =>
|
||||
array(
|
||||
4 =>
|
||||
array (
|
||||
'label' => 'NAS-2',
|
||||
'url' => 'http://nas-2.blackpi.ipv64.net',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'devices',
|
||||
),
|
||||
5 =>
|
||||
array(
|
||||
5 =>
|
||||
array (
|
||||
'label' => 'FritzBox-1',
|
||||
'url' => 'http://fritzbox-1.blackpi.ipv64.net',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'devices',
|
||||
),
|
||||
6 =>
|
||||
array(
|
||||
6 =>
|
||||
array (
|
||||
'label' => 'FritzBox-2',
|
||||
'url' => 'http://fritzbox-2.blackpi.ipv64.net',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'devices',
|
||||
),
|
||||
7 =>
|
||||
array(
|
||||
7 =>
|
||||
array (
|
||||
'label' => 'GS1910-24',
|
||||
'url' => 'http://switch.blackpi.ipv64.net',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'admin',
|
||||
),
|
||||
8 =>
|
||||
array(
|
||||
8 =>
|
||||
array (
|
||||
'label' => 'NWA5121-NI Innen',
|
||||
'url' => 'http://ap-1.blackpi.ipv64.net',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'devices',
|
||||
),
|
||||
9 =>
|
||||
array(
|
||||
9 =>
|
||||
array (
|
||||
'label' => 'NWA5121-NI Aussen',
|
||||
'url' => 'http://ap-2.blackpi.ipv64.net',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'devices',
|
||||
),
|
||||
10 =>
|
||||
array(
|
||||
10 =>
|
||||
array (
|
||||
'label' => 'ZyWALL 110',
|
||||
'url' => 'http://10.233.1248',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'admin',
|
||||
),
|
||||
11 =>
|
||||
array(
|
||||
11 =>
|
||||
array (
|
||||
'label' => 'Ender 3 V3 KE',
|
||||
'url' => 'http://10.233.1.52',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'tools',
|
||||
),
|
||||
12 =>
|
||||
array(
|
||||
12 =>
|
||||
array (
|
||||
'label' => 'Ubuntu NAS',
|
||||
'url' => 'http://10.233.1.32:9000',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'tools',
|
||||
),
|
||||
13 =>
|
||||
array(
|
||||
13 =>
|
||||
array (
|
||||
'label' => 'Backend',
|
||||
'url' => 'https://backend.blackpi.ipv64.net',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'info',
|
||||
),
|
||||
14 =>
|
||||
array(
|
||||
14 =>
|
||||
array (
|
||||
'label' => 'Dev Backend',
|
||||
'url' => 'https://dev-backend.blackpi.ipv64.net',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'info',
|
||||
),
|
||||
15 =>
|
||||
array(
|
||||
15 =>
|
||||
array (
|
||||
'label' => 'Dev Pubic',
|
||||
'url' => 'https://dev-public.blackpi.ipv64.net',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'info',
|
||||
),
|
||||
16 =>
|
||||
array(
|
||||
16 =>
|
||||
array (
|
||||
'label' => 'Local Backend',
|
||||
'url' => 'http://backend.local.ipv64.net',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'info',
|
||||
),
|
||||
17 =>
|
||||
array(
|
||||
17 =>
|
||||
array (
|
||||
'label' => 'Local Pubic',
|
||||
'url' => 'http://public.local.ipv64.net',
|
||||
'newTab' => true,
|
||||
'adminOnly' => false,
|
||||
'group' => 'info',
|
||||
),
|
||||
18 =>
|
||||
array(
|
||||
18 =>
|
||||
array (
|
||||
'label' => 'Proxmox',
|
||||
'url' => 'https://100.88.208.86:8006',
|
||||
'newTab' => true,
|
||||
'adminOnly' => true,
|
||||
'group' => 'devices',
|
||||
),
|
||||
19 =>
|
||||
array(
|
||||
19 =>
|
||||
array (
|
||||
'label' => 'Flatnotes',
|
||||
'url' => 'http://10.233.1.130:8080',
|
||||
'newTab' => true,
|
||||
|
||||
+1
-1
@@ -32,7 +32,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
|
||||
|
||||
logging();
|
||||
sendMail(
|
||||
"Gast Login erfolgreich",
|
||||
"Gast Login Successful",
|
||||
"Benutzer: gast",
|
||||
(new getSpecificData())->getRequestURL(),
|
||||
true,
|
||||
|
||||
@@ -6,6 +6,12 @@ include_once(__DIR__ . '/controller/LogController.php');
|
||||
try {
|
||||
session_start();
|
||||
logging();
|
||||
sendMail(
|
||||
"User Logged Out Successful",
|
||||
(new getSpecificData())->getUsername(),
|
||||
(new getSpecificData())->getRequestURL(),
|
||||
true
|
||||
);
|
||||
$_SESSION = array();
|
||||
|
||||
session_destroy();
|
||||
|
||||
@@ -0,0 +1,101 @@
|
||||
<?php
|
||||
include_once(__DIR__ . '/../controller/DatabaseController.php');
|
||||
include_once(__DIR__ . '/../controller/RoutesController.php');
|
||||
include_once(__DIR__ . '/../modules/Mail.php');
|
||||
|
||||
$view = $_GET['view'] ?? 'show';
|
||||
$selectedService = $_GET['service'] ?? null;
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['add_entry'])) {
|
||||
$titel = $_POST['titel'];
|
||||
$beschreibung = $_POST['beschreibung'];
|
||||
|
||||
DatabaseInsert(
|
||||
"Tickets",
|
||||
"TITEL, BESCHREIBUNG, STATUS, ERSTELLER",
|
||||
$titel,
|
||||
$beschreibung,
|
||||
"OFFEN",
|
||||
ucfirst(strtolower((new getSpecificData())->getUsername())),
|
||||
);
|
||||
|
||||
$html = "Titel: $titel\nBeschreibung: $beschreibung";
|
||||
$user = ucfirst(strtolower((new getSpecificData())->getUsername()));
|
||||
|
||||
sendMail(
|
||||
"Neues Ticket von $user",
|
||||
$html,
|
||||
(new getSpecificData())->getRequestURL(),
|
||||
true,
|
||||
);
|
||||
|
||||
redirectToWebsite((new getSpecificData())->getReferer());
|
||||
exit;
|
||||
}
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['delete_entry'])) {
|
||||
$id = $_POST['id'];
|
||||
|
||||
DatabaseDelete("Tickets", "ID = ?", $id);
|
||||
|
||||
redirectToWebsite((new getSpecificData())->getReferer());
|
||||
exit;
|
||||
}
|
||||
|
||||
$entries = DatabaseShow(
|
||||
"Tickets",
|
||||
"TITEL, BESCHREIBUNG, STATUS",
|
||||
"ERSTELLER = ?",
|
||||
((new getSpecificData())->getUsername()),
|
||||
);
|
||||
|
||||
?>
|
||||
|
||||
<div>
|
||||
<div class="vergabe-form">
|
||||
<h3>Neues Ticket anlegen</h3>
|
||||
<form method="POST" class="vergabe-grid">
|
||||
|
||||
<div class="form-group">
|
||||
<label>Titel</label>
|
||||
<input type="text" name="titel" required>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label>Beschreibung</label>
|
||||
<input type="text" name="beschreibung" required>
|
||||
</div>
|
||||
|
||||
<button type="submit" name="add_entry" class="btn-submit-vergabe">
|
||||
💾 Speichern
|
||||
</button>
|
||||
|
||||
</form>
|
||||
</div>
|
||||
<div class="table-container" style="margin-top: 30px;">
|
||||
<h3>Tickets</h3>
|
||||
|
||||
<?php if (!empty($entries)): ?>
|
||||
<table class="db-table mobile-responsive-table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Titel</th>
|
||||
<th>Beschreibung</th>
|
||||
<th>Status</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach ($entries as $entry): ?>
|
||||
<tr>
|
||||
<td data-label="Titel"><?= htmlspecialchars($entry['TITEL'] ?? '') ?></td>
|
||||
<td data-label="Beschreibung"><?= htmlspecialchars($entry['BESCHREIBUNG'] ?? '') ?></td>
|
||||
<td data-label="Status"><?= htmlspecialchars($entry['STATUS'] ?? '') ?></td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
<?php else: ?>
|
||||
<p>Keine Tickets vorhanden.</p>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,103 @@
|
||||
<?php
|
||||
include_once(__DIR__ . '/../controller/DatabaseController.php');
|
||||
include_once(__DIR__ . '/../controller/RoutesController.php');
|
||||
include_once(__DIR__ . '/../modules/Mail.php');
|
||||
|
||||
$view = $_GET['view'] ?? 'show';
|
||||
$selectedService = $_GET['service'] ?? null;
|
||||
|
||||
$allowedStatuses = ['OFFEN', 'DEPLOYED', 'ABGELEHNT', 'ANGENOMMEN'];
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['edit_entry'])) {
|
||||
$id = $_POST['id'];
|
||||
$status = $_POST['status'] ?? '';
|
||||
|
||||
if (in_array($status, $allowedStatuses, true)) {
|
||||
DatabaseUpdate(
|
||||
"Tickets",
|
||||
"STATUS = ?",
|
||||
"ID = ?",
|
||||
$status,
|
||||
$id
|
||||
);
|
||||
}
|
||||
|
||||
redirectToWebsite((new getSpecificData())->getReferer());
|
||||
exit;
|
||||
}
|
||||
|
||||
if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['delete_entry'])) {
|
||||
$id = $_POST['id'];
|
||||
|
||||
DatabaseDelete(
|
||||
"Tickets",
|
||||
"ID = ?",
|
||||
$id
|
||||
);
|
||||
|
||||
redirectToWebsite((new getSpecificData())->getReferer());
|
||||
exit;
|
||||
}
|
||||
|
||||
$entries = DatabaseShow(
|
||||
"Tickets",
|
||||
"ID, TITEL, BESCHREIBUNG, STATUS, ERSTELLER",
|
||||
);
|
||||
|
||||
?>
|
||||
|
||||
<div>
|
||||
<div class="table-container" style="margin-top: 30px;">
|
||||
<h3>Ticket Verwaltung</h3>
|
||||
|
||||
<?php if (!empty($entries)): ?>
|
||||
<table class="db-table mobile-responsive-table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Titel</th>
|
||||
<th>Beschreibung</th>
|
||||
<th>Status</th>
|
||||
<th>Ersteller</th>
|
||||
<th style="width: 220px;">Aktion</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach ($entries as $entry): ?>
|
||||
<tr>
|
||||
<td data-label="Titel"><?= htmlspecialchars($entry['TITEL'] ?? '') ?></td>
|
||||
<td data-label="Beschreibung"><?= htmlspecialchars($entry['BESCHREIBUNG'] ?? '') ?></td>
|
||||
<td data-label="Status"><?= htmlspecialchars($entry['STATUS'] ?? '') ?></td>
|
||||
<td data-label="Ersteller"><?= htmlspecialchars($entry['ERSTELLER'] ?? '') ?></td>
|
||||
<td data-label="Aktion">
|
||||
<form method="POST"
|
||||
style="margin: 0; display: flex; flex-direction: column; gap: 6px; align-items: stretch;">
|
||||
<input type="hidden" name="id" value="<?= htmlspecialchars($entry['ID'] ?? '') ?>">
|
||||
<select name="status" class="status-select">
|
||||
<?php foreach ($allowedStatuses as $statusOption): ?>
|
||||
<option value="<?= htmlspecialchars($statusOption) ?>"
|
||||
<?= ($entry['STATUS'] ?? '') === $statusOption ? 'selected' : '' ?>>
|
||||
<?= htmlspecialchars($statusOption) ?>
|
||||
</option>
|
||||
<?php endforeach; ?>
|
||||
</select>
|
||||
<button type="submit" name="edit_entry" class="btn-edit">
|
||||
Speichern
|
||||
</button>
|
||||
</form>
|
||||
<form method="POST"
|
||||
style="margin: 0; display: flex; flex-direction: column; gap: 6px; align-items: stretch; margin-top: 3pt;">
|
||||
<input type="hidden" name="id" value="<?= $entry['ID'] ?? '' ?>">
|
||||
<button type="submit" name="delete_entry" class="btn-delete">
|
||||
Löschen
|
||||
</button>
|
||||
</form>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
<?php else: ?>
|
||||
<p>Keine Tickets vorhanden.</p>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
+19
-6
@@ -880,6 +880,17 @@ body.dark-mode .user-table .btn-primary:hover {
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
.btn-edit {
|
||||
background-color: #32b844;
|
||||
color: white;
|
||||
padding: 8px 16px;
|
||||
border: none;
|
||||
border-radius: 4px;
|
||||
cursor: pointer;
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
|
||||
/* ===== Toggle Switch ===== */
|
||||
|
||||
.toggle-card {
|
||||
@@ -981,8 +992,7 @@ body.dark-mode .info-value {
|
||||
width: 100%;
|
||||
border-collapse: collapse;
|
||||
margin-top: 20px;
|
||||
/* table-layout: fixed; */
|
||||
/* sorgt für feste Spaltenbreite */
|
||||
table-layout: fixed;
|
||||
}
|
||||
|
||||
.db-table thead {
|
||||
@@ -996,10 +1006,13 @@ body.dark-mode .info-value {
|
||||
text-align: left;
|
||||
border-bottom: 1px solid var(--card-border);
|
||||
|
||||
/* Wichtig für gleiche Größe */
|
||||
/* overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap; */
|
||||
word-wrap: break-word;
|
||||
overflow-wrap: break-word;
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
.db-table td:nth-child(2) {
|
||||
max-width: 300px;
|
||||
}
|
||||
|
||||
.db-table tr:hover {
|
||||
|
||||
Reference in new issue
Block a user