Upload via GUI (267 Dateien)

This commit is contained in:
2026-10-19 18:06:00 +00:00
parent c800be9693
commit 51656d6578
13 changed files with 516 additions and 54 deletions
+8 -1
View File
@@ -20,7 +20,7 @@ $departments = $pdo->query('SELECT * FROM departments WHERE is_active = 1 ORDER
$priorities = $pdo->query('SELECT * FROM priorities ORDER BY sort_order')->fetchAll();
$helpTopics = help_topic_options($pdo);
$allAgents = $pdo->query('SELECT id, name FROM staff WHERE is_active = 1 ORDER BY name')->fetchAll();
$customFields = $pdo->query('SELECT * FROM custom_fields WHERE is_active = 1 ORDER BY sort_order, label')->fetchAll();
$customFields = $pdo->query('SELECT * FROM custom_fields WHERE is_active = 1 AND department_id IS NULL ORDER BY sort_order, label')->fetchAll();
// Abteilungen auf zugängliche einschränken
if ($myDeptIds !== null) {
@@ -285,6 +285,13 @@ require __DIR__ . '/_header.php';
<option value="<?= e($opt) ?>" <?= $posted === $opt ? 'selected' : '' ?>><?= e($opt) ?></option>
<?php endforeach; ?>
</select>
<?php elseif ($f['field_type'] === 'radio'): ?>
<?php foreach (preg_split('/\r?\n/', trim((string)$f['options'])) as $opt): $opt = trim($opt); if (!$opt) continue; ?>
<label style="display:flex; align-items:center; gap:8px; font-weight:400; margin:4px 0">
<input type="radio" name="<?= $fn ?>" value="<?= e($opt) ?>" style="width:auto" <?= $f['is_required'] ? 'required' : '' ?> <?= $posted === $opt ? 'checked' : '' ?>>
<span><?= e($opt) ?></span>
</label>
<?php endforeach; ?>
<?php elseif ($f['field_type'] === 'checkbox'): ?>
<label style="display:flex; align-items:center; gap:8px; font-weight:400; margin-top:4px">
<input type="checkbox" id="<?= $fn ?>" name="<?= $fn ?>" value="1" style="width:auto" <?= !empty($posted) ? 'checked' : '' ?>>