Refactors the Berichte section from a single hardcoded Jahresbericht into a modular report-building system. Jahresbericht now uses PDFGenerator for corporate identity (logo, colors, headers/footers, cover page). 8 reusable section templates can be freely combined. 6 predefined report templates (Jahres-, Destinatär-, Grundstücks-, Finanz-, Förder-, Pachtbericht) with HTML preview and PDF export. New Bericht-Baukasten UI lets users compose custom reports from individual sections. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
89 lines
2.6 KiB
HTML
89 lines
2.6 KiB
HTML
<!-- Sektion: Pachtbericht -->
|
|
<div class="section">
|
|
<h2>Pachtbericht{% if jahr %} {{ jahr }}{% endif %}</h2>
|
|
|
|
{% if pacht_statistik %}
|
|
<div class="stats-grid">
|
|
<div class="stat-card">
|
|
<div class="value">{{ pacht_statistik.aktive_vertraege }}</div>
|
|
<div class="label">Aktive Pachtverträge</div>
|
|
</div>
|
|
<div class="stat-card">
|
|
<div class="value">€{{ pacht_statistik.total_pachtzins|floatformat:2 }}</div>
|
|
<div class="label">Gesamtpachtzins p.a.</div>
|
|
</div>
|
|
<div class="stat-card">
|
|
<div class="value">{{ pacht_statistik.total_flaeche|floatformat:0 }} qm</div>
|
|
<div class="label">Verpachtete Fläche</div>
|
|
</div>
|
|
<div class="stat-card">
|
|
<div class="value">{{ pacht_statistik.auslaufend_12m }}</div>
|
|
<div class="label">Laufen in 12 Mon. aus</div>
|
|
</div>
|
|
</div>
|
|
{% endif %}
|
|
|
|
{% if pacht_auslaufend %}
|
|
<h3>Auslaufende Verträge (nächste 12 Monate)</h3>
|
|
<table>
|
|
<thead>
|
|
<tr>
|
|
<th>Länderei</th>
|
|
<th>Pächter</th>
|
|
<th>Pachtende</th>
|
|
<th>Pachtzins</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for v in pacht_auslaufend %}
|
|
<tr>
|
|
<td>{{ v.land }}</td>
|
|
<td>{{ v.paechter.get_full_name }}</td>
|
|
<td>{{ v.pachtende|date:"d.m.Y" }}</td>
|
|
<td class="amount">€{{ v.pachtzins_pauschal|floatformat:2 }}</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
{% endif %}
|
|
|
|
{% if verpachtungen %}
|
|
<h3>Alle Verpachtungen</h3>
|
|
<table>
|
|
<thead>
|
|
<tr>
|
|
<th>Länderei</th>
|
|
<th>Pächter</th>
|
|
<th>Fläche</th>
|
|
<th>Pachtzins</th>
|
|
<th>Beginn</th>
|
|
<th>Ende</th>
|
|
<th>Status</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for v in verpachtungen %}
|
|
<tr>
|
|
<td>{{ v.land }}</td>
|
|
<td>{{ v.paechter.get_full_name }}</td>
|
|
<td class="amount">{{ v.verpachtete_flaeche|floatformat:0 }} qm</td>
|
|
<td class="amount">€{{ v.pachtzins_pauschal|floatformat:2 }}</td>
|
|
<td>{{ v.pachtbeginn|date:"d.m.Y" }}</td>
|
|
<td>{% if v.pachtende %}{{ v.pachtende|date:"d.m.Y" }}{% else %}unbefristet{% endif %}</td>
|
|
<td>
|
|
<span class="status-badge status-{{ v.status }}">{{ v.get_status_display }}</span>
|
|
</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
<tfoot>
|
|
<tr style="font-weight: bold; background: #f0f7f4;">
|
|
<td colspan="3">Gesamtpachtzins</td>
|
|
<td class="amount">€{{ total_pachtzins|floatformat:2 }}</td>
|
|
<td colspan="3"></td>
|
|
</tr>
|
|
</tfoot>
|
|
</table>
|
|
{% endif %}
|
|
</div>
|