Files
BeWoPlaner/ReportImp/VkmHamm/Invoicing/CustomInvoiceFactory.cs

26 lines
801 B
C#

using BeWo.Service.Invoicing;
using BS.Shared.DataContracts;
using BS.Shared.DataContracts.Compact;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace VkmHamm.Invoicing
{
public class CustomInvoiceFactory : InvoiceFactory
{
public override InvoiceCreation CreateInvoiceCreator(string specificId, string tenant, Dictionary<CompactSupportConceptDC, List<ServiceRecordDC>> supportConcepts2ServiceRecords)
{
foreach (var sc in supportConcepts2ServiceRecords.Keys)
{
if (sc.CostBearer.ToLower().Contains("jugendamt hamm"))
return new JugendamtInvoiceCreation();
}
return new CustomInvoiceCreation();
}
}
}