[IMP] l10n_at_hr_payroll: TASY-Tarifsystem-Katalog, AGRD-Auswahl, DG-Kosten-/Lohnkonten-Reports, Wr.-DAG-Grundlagen (AP0-AP3)

AP0 Variante b — TASY-Tarifsystem-Katalog:
- Neue Katalogmodelle (BSGR/ERGB/Dienstgebergruppen/Tarifgruppen/
  Tarifsets/Tarife/Zuordnungen/Zu-Abschläge inkl. Steuerung),
  models/tasy_katalog.py — Auflösung Tarifgruppe (BSGR+ERGB+DGG)
  -> Sätze je Verrechnungsbasis
- Import-Wizard l10n.at.payroll.tasy.katalog.wizard (alle Träger,
  sektionsscharf, idempotent), Views/Menüs, Security
- Realexport-Test gegen TASY-LSWH-Export (B001/B002 = 39,05/37,55 %)

AP1 — eSV-Abmeldegründe (DM-ORG D.22):
- l10n_at_agrd Char -> vollständige Selection (33 Codes),
  Seed der Standard-Abgangsursachen (noupdate, hr-Defaults vorverbunden),
  Form-/Listen-Erbe

AP2a-c — Auswertungen:
- Monatsjournal: eigener Dienstgeberanteile-Block (ATP_DG vorher
  still ausgefiltert); Fix: models/monatsreports.py war nie in
  models/__init__.py importiert (GP7-Reports waren toter Code)
- Neuer Report Dienstgeber-Gesamtkosten (Brutto + LNK aufgeschlüsselt/
  kumuliert je AN + Laufsummen, Spalten FLAF/KommSt/DZ/BV/Wr. DAG)
- Jahreslohnkonto je DN + Betriebsjahreslohnkonto (Jahresbericht-
  Wizard, Monatsmatrix je Lohnart), report/jahresreports.xml

AP3 — Wr. Dienstgeberabgabe (RIS LrW GesNr 20000133 verifiziert):
- Company-Flag l10n_at_wien_dag (Kern), Fristenarten wien_dag/
  wien_dag_jahres (cron-geflaggt, 15./31. 3.), Company-View-Feld,
  Wr.-DAG-Spalte im DG-Kosten-Report
This commit is contained in:
2026-09-12 23:17:00 +02:00
parent 3c5cc3aded
commit 3c85cc6790
16 changed files with 1999 additions and 35 deletions
@@ -38,6 +38,17 @@
<field name="binding_type">report</field>
</record>
<record id="action_report_dg_kosten" model="ir.actions.report">
<field name="name">Dienstgeber-Gesamtkosten</field>
<field name="model">hr.payslip.run</field>
<field name="report_type">qweb-pdf</field>
<field name="report_name">l10n_at_hr_payroll.report_dg_kosten</field>
<field name="report_file">l10n_at_hr_payroll.report_dg_kosten</field>
<field name="paperformat_id" ref="hr_payroll.paperformat_euro_light"/>
<field name="binding_model_id" ref="hr_payroll.model_hr_payslip_run"/>
<field name="binding_type">report</field>
</record>
<!-- Lohnzettel AT: AT-Layout — Lohnarten nach Kategorie, DN-Abzüge,
DG-Anteile (SV-DG, FLAF, KommSt, DZ, BV), Netto. -->
<template id="report_lohnzettel_at">
@@ -170,13 +181,15 @@
</t>
</template>
<!-- Monatsjournal: je Lohnart die Summe über den Lauf -->
<!-- Monatsjournal: je Lohnart die Summe über den Lauf — Bezüge/ -->
<!-- Abzüge und (seit AP2a) eigener Block Dienstgeberanteile. -->
<template id="report_monatsjournal">
<t t-call="web.html_container">
<t t-foreach="journal" t-as="j">
<t t-call="web.external_layout">
<div class="page">
<h2>Monatsjournal — <t t-out="j['run'].name"/></h2>
<h4>Bezüge &amp; Abzüge</h4>
<table class="table table-sm">
<thead>
<tr>
@@ -193,6 +206,92 @@
<td><t t-out="art['bemessung']"/></td>
<td class="text-end"><span t-out="art['summe']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: j['run'].company_id.currency_id}"/></td>
</tr>
<tr>
<td colspan="3"><strong>Summe Bezüge &amp; Abzüge</strong></td>
<td class="text-end"><strong><span t-out="j['summe_arten']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: j['run'].company_id.currency_id}"/></strong></td>
</tr>
</tbody>
</table>
<h4>Dienstgeberanteile (Lohnnebenkosten)</h4>
<table class="table table-sm">
<thead>
<tr>
<th>Code</th>
<th>Position</th>
<th>Bemessung</th>
<th class="text-end">Summe</th>
</tr>
</thead>
<tbody>
<tr t-foreach="j['dg_arten']" t-as="art">
<td><t t-out="art['code']"/></td>
<td><t t-out="art['name']"/></td>
<td><t t-out="art['bemessung']"/></td>
<td class="text-end"><span t-out="art['summe']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: j['run'].company_id.currency_id}"/></td>
</tr>
<tr>
<td colspan="3"><strong>Summe Dienstgeberanteile</strong></td>
<td class="text-end"><strong><span t-out="j['summe_dg']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: j['run'].company_id.currency_id}"/></strong></td>
</tr>
</tbody>
</table>
</div>
</t>
</t>
</t>
</template>
<!-- Dienstgeber-Gesamtkosten: Brutto + Lohnnebenkosten je AN, -->
<!-- aufgeschlüsselt und kumuliert (AP2a). -->
<template id="report_dg_kosten">
<t t-call="web.html_container">
<t t-foreach="docs" t-as="run">
<t t-call="web.external_layout">
<div class="page">
<h2>Dienstgeber-Gesamtkosten — <t t-out="run.name"/></h2>
<table class="table table-sm">
<thead>
<tr>
<th>Mitarbeiter:in</th>
<th class="text-end">Bruttolohn</th>
<th class="text-end">SV-DG (laufend+SZ)</th>
<th class="text-end">FLAF-DB</th>
<th class="text-end">KommSt</th>
<th class="text-end">DZ (WKO)</th>
<th class="text-end">BV</th>
<th class="text-end">Wr. DAG</th>
<th class="text-end">Weitere DG</th>
<th class="text-end">Σ Lohnnebenkosten</th>
<th class="text-end">Gesamtkosten</th>
</tr>
</thead>
<tbody>
<tr t-foreach="zeilen" t-as="z">
<td><t t-out="z['slip'].employee_id.name"/></td>
<td class="text-end"><span t-out="z['brutto']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></td>
<td class="text-end"><span t-out="z['svdg']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></td>
<td class="text-end"><span t-out="z['spalten']['FLAFDB']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></td>
<td class="text-end"><span t-out="z['spalten']['KOMMST']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></td>
<td class="text-end"><span t-out="z['spalten']['DZ']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></td>
<td class="text-end"><span t-out="z['spalten']['BVG']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></td>
<td class="text-end"><span t-out="z['spalten']['WIEN_DAG']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></td>
<td class="text-end"><span t-out="z['weitere']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></td>
<td class="text-end"><span t-out="z['dg_summe']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></td>
<td class="text-end"><strong><span t-out="z['gesamtkosten']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></strong></td>
</tr>
<tr>
<td><strong>Summe Lauf</strong></td>
<td class="text-end"><strong><span t-out="summen['brutto']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></strong></td>
<td class="text-end"><strong><span t-out="summen['svdg']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></strong></td>
<td class="text-end"><strong><span t-out="summen['spalten']['FLAFDB']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></strong></td>
<td class="text-end"><strong><span t-out="summen['spalten']['KOMMST']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></strong></td>
<td class="text-end"><strong><span t-out="summen['spalten']['DZ']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></strong></td>
<td class="text-end"><strong><span t-out="summen['spalten']['BVG']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></strong></td>
<td class="text-end"><strong><span t-out="summen['spalten']['WIEN_DAG']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></strong></td>
<td class="text-end"><strong><span t-out="summen['weitere']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></strong></td>
<td class="text-end"><strong><span t-out="summen['dg_summe']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></strong></td>
<td class="text-end"><strong><span t-out="summen['gesamtkosten']" t-options="{&quot;widget&quot;: &quot;monetary&quot;, &quot;display_currency&quot;: run.company_id.currency_id}"/></strong></td>
</tr>
</tbody>
</table>
</div>
@@ -0,0 +1,138 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<!-- ============================================================ -->
<!-- AP2b/AP2c: Jahreslohnkonto je Dienstnehmer:in und -->
<!-- Betriebsjahreslohnkonto — Monatsmatrix je Lohnart; Druck -->
<!-- über den Wizard l10n.at.payroll.jahresbericht.wizard. -->
<!-- ============================================================ -->
<record id="action_report_jahreslohnkonto" model="ir.actions.report">
<field name="name">Jahreslohnkonto (Dienstnehmer:in)</field>
<field name="model">hr.employee</field>
<field name="report_type">qweb-pdf</field>
<field name="report_name">l10n_at_hr_payroll.report_jahreslohnkonto</field>
<field name="report_file">l10n_at_hr_payroll.report_jahreslohnkonto</field>
<field name="paperformat_id" ref="hr_payroll.paperformat_euro_light"/>
</record>
<record id="action_report_betriebslohnkonto" model="ir.actions.report">
<field name="name">Betriebsjahreslohnkonto</field>
<field name="model">res.company</field>
<field name="report_type">qweb-pdf</field>
<field name="report_name">l10n_at_hr_payroll.report_betriebslohnkonto</field>
<field name="report_file">l10n_at_hr_payroll.report_betriebslohnkonto</field>
<field name="paperformat_id" ref="hr_payroll.paperformat_euro_light"/>
</record>
<template id="report_jahreslohnkonto">
<t t-call="web.html_container">
<t t-foreach="berichte" t-as="b">
<t t-call="web.external_layout">
<div class="page">
<h2>Jahreslohnkonto <t t-out="jahr"/><t t-out="b['employee'].name"/></h2>
<table class="table table-sm">
<thead>
<tr>
<th>Code</th>
<th>Lohnart</th>
<th>Kategorie</th>
<th class="text-end" t-foreach="range(1, 13)" t-as="monat">
<t t-out="monat"/>
</th>
<th class="text-end">Jahr</th>
</tr>
</thead>
<tbody>
<tr t-foreach="b['zeilen']" t-as="zeile">
<td><t t-out="zeile['code']"/></td>
<td><t t-out="zeile['name']"/></td>
<td><t t-out="zeile['kategorie']"/></td>
<td class="text-end" t-foreach="zeile['monate']" t-as="wert">
<span t-out="wert" t-options='{"widget": "monetary", "display_currency": b["employee"].company_id.currency_id}'/>
</td>
<td class="text-end"><strong><span t-out="zeile['total']" t-options='{"widget": "monetary", "display_currency": b["employee"].company_id.currency_id}'/></strong></td>
</tr>
</tbody>
</table>
</div>
</t>
</t>
</t>
</template>
<template id="report_betriebslohnkonto">
<t t-call="web.html_container">
<t t-foreach="berichte" t-as="b">
<t t-call="web.external_layout">
<div class="page">
<h2>Betriebsjahreslohnkonto <t t-out="jahr"/><t t-out="b['company'].name"/></h2>
<table class="table table-sm">
<thead>
<tr>
<th>Code</th>
<th>Lohnart</th>
<th>Kategorie</th>
<th class="text-end" t-foreach="range(1, 13)" t-as="monat">
<t t-out="monat"/>
</th>
<th class="text-end">Jahr</th>
</tr>
</thead>
<tbody>
<tr t-foreach="b['zeilen']" t-as="zeile">
<td><t t-out="zeile['code']"/></td>
<td><t t-out="zeile['name']"/></td>
<td><t t-out="zeile['kategorie']"/></td>
<td class="text-end" t-foreach="zeile['monate']" t-as="wert">
<span t-out="wert" t-options='{"widget": "monetary", "display_currency": b["company"].currency_id}'/>
</td>
<td class="text-end"><strong><span t-out="zeile['total']" t-options='{"widget": "monetary", "display_currency": b["company"].currency_id}'/></strong></td>
</tr>
</tbody>
</table>
</div>
</t>
</t>
</t>
</template>
<!-- Druck-Wizard -->
<record id="jahresbericht_wizard_form_view" model="ir.ui.view">
<field name="name">l10n.at.payroll.jahresbericht.wizard.form</field>
<field name="model">l10n.at.payroll.jahresbericht.wizard</field>
<field name="arch" type="xml">
<form string="Jahresberichte drucken">
<group>
<group>
<field name="jahr"/>
<field name="art"/>
</group>
<group>
<field name="company_id"
groups="base.group_multi_company"/>
<field name="employee_ids" widget="many2many_tags"
invisible="art != 'dn'"/>
</group>
</group>
<footer>
<button string="Drucken" name="action_drucken"
type="object" class="btn-primary"/>
<button string="Abbrechen" class="btn-secondary"
special="cancel"/>
</footer>
</form>
</field>
</record>
<record id="action_jahresbericht_wizard" model="ir.actions.act_window">
<field name="name">Jahresberichte (Lohnkonten)</field>
<field name="res_model">l10n.at.payroll.jahresbericht.wizard</field>
<field name="view_mode">form</field>
<field name="target">new</field>
</record>
<menuitem id="menu_l10n_at_payroll_jahresberichte"
name="Jahresberichte (Lohnkonten)"
parent="menu_l10n_at_payroll_root"
action="action_jahresbericht_wizard" sequence="80"/>
</odoo>