45 lines
1.6 KiB
C#
45 lines
1.6 KiB
C#
using System;
|
|
using BeWo.Report;
|
|
using BeWo.Report.ReportObjects;
|
|
|
|
using DevExpress.XtraReports.UI;
|
|
|
|
namespace Humanitas
|
|
{
|
|
public partial class ServiceInvoiceReport : XtraReport, IBeWoReport<ServiceInvoiceRO>
|
|
{
|
|
public ServiceInvoiceReport()
|
|
{
|
|
this.InitializeComponent();
|
|
}
|
|
|
|
public void SetReportDataSource(ServiceInvoiceRO pRO)
|
|
{
|
|
DateTime start = pRO.AccountingPeriodStart;
|
|
DateTime end = pRO.AccountingPeriodEnd;
|
|
if (start.Month == end.Month && start.Year == end.Year)
|
|
{
|
|
lblAbrechnungszeitraum.Text = String.Format("hiermit berechnen wir für den Monat {0:MMMM yyyy} folgende erbrachte Tätigkeiten:", start);
|
|
}
|
|
else
|
|
{
|
|
lblAbrechnungszeitraum.Text = String.Format("hiermit berechnen wir für den Zeitraum {0:MMMM yyyy} - {1:MMMM yyyy} folgende erbrachte Tätigkeiten:", start, end);
|
|
}
|
|
|
|
if (!String.IsNullOrWhiteSpace(pRO.RecipientOrganisation) &&
|
|
pRO.RecipientOrganisation.StartsWith("Landeshauptstadt Düsseldorf - Jugendamt"))
|
|
{
|
|
lblAbrechnung.Text = String.Format("Rechnung für ambulante Hilfen gem. § 41 SGB VIII i.V.m. § 35a (SGB VIII) (Eingliederungshilfe) für {0} {1}, AZ.: {2}", pRO.CustomerSalutation, pRO.CustomerName, pRO.CustomerReferenceNumber);
|
|
|
|
foreach (var sip in pRO.ServiceInvoicePeriods)
|
|
{
|
|
foreach (var ii in sip.ServiceInvoiceItems)
|
|
{
|
|
ii.ServiceDescription = "ambulante Hilfen";
|
|
}
|
|
}
|
|
}
|
|
this.bindingSource1.DataSource = pRO;
|
|
}
|
|
}
|
|
} |