2023-03-31 10:26:29 +02:00
|
|
|
using System;
|
2018-04-27 14:23:43 +02:00
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using BeWo.Report;
|
|
|
|
|
using BeWo.Report.ReportObjects;
|
|
|
|
|
|
2018-06-13 14:38:35 +02:00
|
|
|
namespace Humanitas
|
2018-04-27 14:23:43 +02:00
|
|
|
{
|
|
|
|
|
public partial class Stundenzettel : DevExpress.XtraReports.UI.XtraReport, IBeWoReport<ServicesOverviewRO>
|
|
|
|
|
{
|
|
|
|
|
public Stundenzettel()
|
|
|
|
|
{
|
|
|
|
|
InitializeComponent();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void SetReportDataSource(ServicesOverviewRO pRO)
|
|
|
|
|
{
|
|
|
|
|
if (pRO.Services != null)
|
|
|
|
|
{
|
|
|
|
|
List<ServicesOverviewRO.ServiceDetail> servicesBillable = new List<ServicesOverviewRO.ServiceDetail>();
|
|
|
|
|
|
2023-03-31 10:26:29 +02:00
|
|
|
foreach (var sd in pRO.Services)
|
2018-04-27 14:23:43 +02:00
|
|
|
{
|
2023-03-31 10:26:29 +02:00
|
|
|
if (sd.IsBillable)
|
|
|
|
|
{
|
|
|
|
|
if (sd.ServiceDescription.ToLower().Contains("fehlkontakt"))
|
|
|
|
|
{
|
|
|
|
|
sd.Notice5 = "Fehlkontakt";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
else if (sd.IsGroup)
|
|
|
|
|
{
|
|
|
|
|
sd.Notice5 = String.Format("{0} Teilnehmer", sd.CustomerCount);
|
|
|
|
|
}
|
|
|
|
|
servicesBillable.Add(sd);
|
|
|
|
|
}
|
2018-04-27 14:23:43 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
pRO.Services = servicesBillable;
|
|
|
|
|
}
|
|
|
|
|
this.bindingSource1.DataSource = pRO;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|