1.3.0 Geburtstagslogik verbessert

This commit is contained in:
Borgal
2025-11-16 21:26:21 +01:00
parent ddcd614a49
commit 0cb4ca932c
3 changed files with 80 additions and 55 deletions

View File

@@ -180,10 +180,10 @@ if ($row) {
}
// --- ZAHLENDE PERSON BESTIMMEN ---
$next_payer_username = null;
$next_payer_info = null;
if ($total_accepted > 0) {
include_once('zahler.php');
$next_payer_username = get_next_payer_username($conn, $meeting_id);
$next_payer_info = get_next_payer_info($conn, $meeting_id);
}
@@ -369,10 +369,15 @@ $german_weekdays = [
<!-- Horizontale Linie hier einfügen -->
<hr class="my-1">
<?php if ($next_payer_username): ?>
<?php if ($next_payer_info): ?>
<div class="text-center my-2 mx-auto" style="max-width: 500px; border-radius: 0.5rem;">
<p class="fw-bold mb-1">Rechnung wird bezahlt von:</p>
<h4 class="text-muted fw-bold mb-0"><?= htmlspecialchars($next_payer_username); ?></h4>
<h4 class="text-muted fw-bold mb-0">
<?= htmlspecialchars($next_payer_info['username']); ?>
<?php if ($next_payer_info['is_birthday_payer']): ?>
<span class="material-symbols-outlined align-text-bottom" style="font-size: 1.1em; color: #ff6f00;" title="Geburtstagsvorschlag">cake</span>
<?php endif; ?>
</h4>
</div>
<?php endif; ?>