using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using BeWo.Data.Access;
using BeWo.Data.Entities;
using BeWo.Service.Invoicing;
using BS.Shared.Core;
using BS.Shared.DataContracts;
using BS.Shared.Services;

namespace BloemelingUndTeckhaus.Invoicing
{

	public class BeWoRueckenwindAssistenzInvoiceCreation : InvoiceCreation
    {
		public override void SetInvoiceId(ServiceInvoice invoice)
		{
			invoice.InvoiceBase.InvoiceId = "Assistenz";
            invoice.InvoiceBase.InvoiceTypeText = "Assistenzleistung";
		}

	    public override InvoiceItem CreateInvoiceItem(ServiceRecordDC iServiceRecord, SupportConceptApprovalPeriod scap, Calculations calc)
	    {
	        if (!iServiceRecord.ServiceDescription.CategoryName.Contains("Assistenz"))
	        {
	            return null;
	        }
	        return base.CreateInvoiceItem(iServiceRecord, scap, calc);
	    }

	    //public override IList<InvoiceItem> CreateSummaryInvoiceItems(IList<InvoiceItem> itemList, DateTimeSpan invoicePeriod, SupportConceptApprovalPeriod scap,
		//	Calculations calc)
		//{
		//	return itemList;
		//}
    }
}
