43 lines
1.2 KiB
C#
43 lines
1.2 KiB
C#
using System;
|
|
using System.Linq;
|
|
using BeWo.Report;
|
|
using BeWo.Report.ReportObjects;
|
|
|
|
using DevExpress.XtraReports.UI;
|
|
|
|
namespace VaroSozialagentur
|
|
{
|
|
public partial class ServiceInvoiceReport : XtraReport, IBeWoReport<ServiceInvoiceRO>
|
|
{
|
|
public ServiceInvoiceReport()
|
|
{
|
|
this.InitializeComponent();
|
|
}
|
|
|
|
public void SetReportDataSource(ServiceInvoiceRO pRO)
|
|
{
|
|
string[] start = pRO.AccountingPeriodStart.ToString().Split(' ');
|
|
string[] ende = pRO.AccountingPeriodEnd.ToString().Split(' ');
|
|
|
|
if (pRO.ServiceInvoicePeriods != null)
|
|
{
|
|
foreach (var sip in pRO.ServiceInvoicePeriods)
|
|
{
|
|
if (sip.ServiceInvoiceItems != null)
|
|
{
|
|
foreach (var ii in sip.ServiceInvoiceItems)
|
|
{
|
|
if (ii.UnitDescription == "Stunde")
|
|
ii.UnitDescription = "Fachleistungsstunde";
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
lblZeitraum.Text += start[0] + " - " + ende[0];
|
|
|
|
this.bindingSource1.DataSource = pRO;
|
|
}
|
|
|
|
}
|
|
} |