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

29 lines
807 B
C#

using System;
using System.Collections.Generic;
using BeWo.Service.Invoicing;
using BS.Shared.DataContracts;
using BS.Shared.DataContracts.Compact;
using BS.Shared.Services;
namespace ProIntegra.Invoicing
{
public class CustomInvoiceFactory : InvoiceFactory
{
public override InvoiceCreation CreateInvoiceCreator(string specificId, string tenant, Dictionary<CompactSupportConceptDC, List<ServiceRecordDC>> supportConcepts2ServiceRecords)
{
foreach (var item in supportConcepts2ServiceRecords)
{
var csc = item.Key;
if (csc.CostBearer.ToLower().Contains("neu"))
{
return new CustomInvoiceCreation();
}
}
return new InvoiceCreation();
}
}
}