From 5d8de2db55a459715e94faa00ddbe20d533c4c7f Mon Sep 17 00:00:00 2001 From: HirschleM Date: Mon, 29 Jun 2026 14:38:06 +0200 Subject: [PATCH] =?UTF-8?q?MH:=20VSD=20Hamm=20K=C3=BCrzung=20von=20Spitzab?= =?UTF-8?q?rechnungen=20Bugfix=20SupportOID=3D166466?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ReportImp/VSDHammReports/CustomSettlementInvoiceCreation.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ReportImp/VSDHammReports/CustomSettlementInvoiceCreation.cs b/ReportImp/VSDHammReports/CustomSettlementInvoiceCreation.cs index 53c618103..3cda37c9e 100644 --- a/ReportImp/VSDHammReports/CustomSettlementInvoiceCreation.cs +++ b/ReportImp/VSDHammReports/CustomSettlementInvoiceCreation.cs @@ -264,10 +264,12 @@ namespace VSDHammReports { //Christian wars:-) var dauerBudgetMitRf = dauerBudget * ((ap.RateFactor ?? 0) + 100) / 100; + var scap = c2s.ApprovalPeriodList.FirstOrDefault(a => ap.PeriodStartDate >= a.StartDate && ap.PeriodStartDate <= a.EndDate); + if (SchneideBeiErreichenDesBudgetsAb) { // Claude: Bei Wochen-/Monatsbewilligung auf Intervall-Ebene kappen statt auf Gesamtebene. - if (ap.ApprovalUnit == AccountingIntervalType.Weekly || ap.ApprovalUnit == AccountingIntervalType.Monthly) + if (scap != null && !scap.IsApprovedBEShifting && ap.ApprovalUnit == AccountingIntervalType.Weekly || ap.ApprovalUnit == AccountingIntervalType.Monthly) { // Claude: Bewilligte Minuten pro Intervall (ApprovedPerUnit ist die Menge je Woche bzw. Monat). DateTime intervalKey = ap.ApprovalUnit == AccountingIntervalType.Weekly