Reorganize into monorepo layout, move mitarbeiter-app to legacy reference

Consolidates the previously separate omsorgapp and omsorgCore repos
(each had their own nested .git with GitHub history) plus the old
root-level website/mitarbeiter-app into a single monorepo, matching
the structure already documented in the root CLAUDE.md. Also moves
the PHP employee app aside as omsorgWeb/mitarbeiter-app-legacy/ to
serve as a template for a ground-up rewrite.

Fixes .gitignore in the same pass: the config-secrets/uploads/data
patterns were unanchored (relative to repo root, not depth-agnostic),
so they silently stopped matching once the app moved under omsorgWeb/.
Patterns are now **/-prefixed and cover both mitarbeiter-app and
mitarbeiter-app-legacy, keeping DB/SMTP credentials and uploaded
employee documents out of version control.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
Felix Kemmler
2026-08-07 14:21:37 +02:00
co-authored by Claude Sonnet 5
parent 8beb0fcf52
commit b6c1389c55
355 changed files with 24348 additions and 361 deletions
@@ -0,0 +1,116 @@
<?php
require_once __DIR__ . '/../lib/auth.php';
require_once __DIR__ . '/../lib/layout.php';
require_login();
$user_id = current_user()['id'];
$materials = db()->query('SELECT * FROM fortbildung_materials ORDER BY sort_order ASC, id ASC')->fetchAll();
$stmt = db()->prepare('SELECT * FROM requests_fortbildungsantrag WHERE user_id = ? ORDER BY created_at DESC');
$stmt->execute([$user_id]);
$requests = $stmt->fetchAll();
$anliegen_labels = [
'wbl_pdl' => 'Anfrage WBL/PDL Weiterbildung',
'fortbildung' => 'Fortbildung anfragen',
'pflichtschulung' => 'Pflichtschulung',
];
$status_labels = ['pending' => 'Ausstehend', 'accepted' => 'Akzeptiert', 'rejected' => 'Abgelehnt'];
layout_start('OMSORG Fortbildungsantrag', 'fortbildungsantrag');
?>
<h1 class="main-title">🎓 Fortbildungs&shy;antrag</h1>
<p class="main-sub">Unterlagen herunterladen und Fortbildungsanträge einreichen.</p>
<?php if (isset($_GET['success'])): ?>
<div class="success" style="margin-top:16px">Antrag erfolgreich eingereicht.</div>
<?php elseif (isset($_GET['error'])): ?>
<div class="error" style="margin-top:16px"><?= e(urldecode($_GET['error'])) ?></div>
<?php endif; ?>
<div class="page-split" style="margin-top:24px">
<div class="page-split-list">
<h2>Unterlagen</h2>
<?php if (empty($materials)): ?>
<p style="color:var(--muted)">Noch keine Unterlagen verfügbar.</p>
<?php else: ?>
<div class="downloads-grid">
<?php foreach ($materials as $m): ?>
<div class="glass download-card">
<h3 class="download-card-title"><?= e($m['title']) ?></h3>
<?php if ($m['description'] !== ''): ?>
<p class="download-card-desc"><?= e($m['description']) ?></p>
<?php endif; ?>
<a href="fortbildung-serve.php?id=<?= (int)$m['id'] ?>" class="btn download-btn">&#8595; Herunterladen</a>
</div>
<?php endforeach; ?>
</div>
<?php endif; ?>
</div>
<div class="page-split-form">
<div class="glass detail-card">
<h2>Neuer Antrag</h2>
<form action="../actions/submit-fortbildungsantrag.php" method="post" enctype="multipart/form-data">
<?= csrf_field() ?>
<label>
<span>Anliegen <span style="color:#ff8080">*</span></span>
<select name="anliegen" required>
<option value=""> Bitte wählen </option>
<option value="wbl_pdl">Anfrage WBL/PDL Weiterbildung</option>
<option value="fortbildung">Fortbildung anfragen</option>
<option value="pflichtschulung">Pflichtschulung</option>
</select>
</label>
<label>
<span>Thema <span style="color:#ff8080">*</span></span>
<input type="text" name="thema" required placeholder="z. B. Erste Hilfe, Demenzpflege …">
</label>
<label>
Nachricht
<textarea name="nachricht" rows="4" placeholder="Weitere Informationen oder Wünsche"></textarea>
</label>
<label>
Anhang
<input type="file" name="datei" accept=".pdf,.doc,.docx,.jpg,.jpeg,.png">
<span class="hint">PDF, Word, JPG, PNG &mdash; max. 12 MB (optional)</span>
</label>
<button type="submit" class="btn" style="margin-top:6px">Antrag einreichen</button>
</form>
</div>
</div>
</div>
<?php if (!empty($requests)): ?>
<div style="margin-top:40px">
<h2>Meine Anträge</h2>
<table class="requests-table">
<thead>
<tr>
<th>Anliegen</th>
<th>Thema</th>
<th>Eingereicht</th>
<th>Status</th>
<th>Notiz</th>
</tr>
</thead>
<tbody>
<?php foreach ($requests as $r): ?>
<tr>
<td><?= e($anliegen_labels[$r['anliegen']] ?? $r['anliegen']) ?></td>
<td style="font-weight:800"><?= e($r['thema']) ?></td>
<td style="color:var(--muted);font-size:.9rem"><?= e(date('d.m.Y', strtotime($r['created_at']))) ?></td>
<td><span class="badge badge-<?= e($r['status']) ?>"><?= e($status_labels[$r['status']] ?? $r['status']) ?></span></td>
<td style="color:var(--muted);font-size:.9rem"><?= $r['admin_note'] !== '' ? e($r['admin_note']) : '' ?></td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>
<?php endif; ?>
<?php layout_end(); ?>