36 lines
751 B
C#
36 lines
751 B
C#
using BeWo.Data.Entities;
|
|
using BeWo.Report;
|
|
using BeWo.Report.ReportObjects;
|
|
using BS.Shared;
|
|
using BS.Shared.Core;
|
|
using DevExpress.XtraReports.UI;
|
|
using System;
|
|
|
|
namespace LebenshilfeBadKreuznachAutismuszentrum
|
|
{
|
|
public partial class Rechnung : XtraReport, IBeWoReport<ServiceInvoiceRO>
|
|
{
|
|
public Rechnung()
|
|
{
|
|
this.InitializeComponent();
|
|
}
|
|
|
|
public void SetReportDataSource(ServiceInvoiceRO pRO)
|
|
{
|
|
decimal hours = 0;
|
|
if (pRO.ServiceInvoicePeriods != null)
|
|
{
|
|
foreach (var sip in pRO.ServiceInvoicePeriods)
|
|
{
|
|
foreach (var ii in sip.ServiceInvoiceItems)
|
|
{
|
|
hours += ii.Hours ?? 0;
|
|
}
|
|
}
|
|
|
|
}
|
|
|
|
this.bindingSource1.DataSource = pRO;
|
|
}
|
|
}
|
|
} |