MH: LyvieKupfer in Rechnung Items nach Leistung aufteilen

This commit is contained in:
2025-01-30 11:07:28 +01:00
parent b421ee26c5
commit 0fa3cd3d2e
3 changed files with 26 additions and 1 deletions

View File

@@ -0,0 +1,24 @@
using BeWo.Data.Entities;
using BeWo.Service.Invoicing;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace LyvieKupfer.Invoicing
{
public class CustomInvoiceCreation : InvoiceCreation
{
public override string GetSummaryItemKey(SupportConceptApprovalPeriod scap, InvoiceItem iitem, bool summaryPerMonth)
{
String key = String.Format("{0:0.0000}_{1}_{2}", iitem.AmountPerUnit, iitem.RateFactor, iitem.ItemDescription);
if (summaryPerMonth)
{
key = String.Format("{0:0.0000}_{1}_{2:yyyyMM}_{3}", iitem.AmountPerUnit, iitem.RateFactor, iitem.ItemPeriodStart, iitem.ItemDescription);
}
return key;
}
}
}

View File

@@ -17,7 +17,7 @@ namespace LyvieKupfer.Invoicing
return new CollectiveInvoiceCreation();
}
}
return new InvoiceCreation();
return new CustomInvoiceCreation();
}
}
}

View File

@@ -57,6 +57,7 @@
<ItemGroup>
<Compile Include="Calculations\CustomGroupDurationCalculator.cs" />
<Compile Include="Invoicing\CollectiveInvoiceCreation.cs" />
<Compile Include="Invoicing\CustomInvoiceCreation.cs" />
<Compile Include="Invoicing\CustomInvoiceFactory.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Quittierungsbeleg.cs">