Files
BeWoPlaner/ReportImp/WMB/SettlementReport.cs

56 lines
2.8 KiB
C#
Raw Permalink Normal View History

2016-06-27 01:45:38 +02:00
using System;
using BeWo.Report.ReportObjects;
using BeWo.Report;
2017-06-11 15:50:31 +02:00
namespace WMB
2016-06-27 01:45:38 +02:00
{
public partial class Spitzabrechnung : DevExpress.XtraReports.UI.XtraReport, IBeWoReport<SettlementRO>
{
public Spitzabrechnung()
{
InitializeComponent();
}
public void SetReportDataSource(SettlementRO pRO)
{
2017-06-11 15:50:31 +02:00
pRO.ApprovedFLSWithFactor = String.Format("{0:0.00}", pRO.RecordedFLSTotal*(double)pRO.RateFactor);
if (!String.IsNullOrWhiteSpace(pRO.AmountRecordedFLSString))
pRO.AmountRecordedFLSString = pRO.AmountRecordedFLSString.Replace("<22>", "").Trim();
if (!String.IsNullOrWhiteSpace(pRO.AmountAdvancedPayments))
pRO.AmountAdvancedPayments = pRO.AmountAdvancedPayments.Replace("<22>", "").Trim();
if (!String.IsNullOrWhiteSpace(pRO.Claim))
pRO.Claim = pRO.Claim.Replace("<22>", "").Trim();
2016-06-27 01:45:38 +02:00
if (pRO.DifferentHourlyRateCount == 3)
{
2017-06-11 15:50:31 +02:00
pRO.Abrechnungstext1 = String.Format("{2:0.00} Fachleistungsstunden in der Zeit vom {0} - {1}",
pRO.AccountingStartDateString, pRO.HourlyRate3EndDateString, pRO.GeleisteteFLSMitStundensatz3 * pRO.RateFactor);
pRO.Abrechnungstext2 = String.Format("{2:0.00} Fachleistungsstunden in der Zeit vom {0} - {1}",
pRO.HourlyRateOldStartDateString, pRO.HourlyRateOldEndDateString, pRO.GeleisteteFLSMitStundensatzAlt * pRO.RateFactor);
pRO.Abrechnungstext3 = String.Format("{2:0.00} Fachleistungsstunden in der Zeit vom {0} - {1}",
pRO.HourlyRateNewStartDateString, pRO.AccountingEndDateString, pRO.GeleisteteFLSMitStundensatzAktuell * pRO.RateFactor);
2016-06-27 01:45:38 +02:00
}
else if (pRO.DifferentHourlyRateCount == 2)
{
2017-06-11 15:50:31 +02:00
pRO.Abrechnungstext2 = String.Format("{2:0.00} Fachleistungsstunden in der Zeit vom {0} - {1}",
pRO.AccountingStartDateString, pRO.HourlyRateOldEndDateString, pRO.GeleisteteFLSMitStundensatzAlt * pRO.RateFactor);
2016-06-27 01:45:38 +02:00
2017-06-11 15:50:31 +02:00
pRO.Abrechnungstext3 = String.Format("{2:0.00} Fachleistungsstunden in der Zeit vom {0} - {1}",
pRO.HourlyRateNewStartDateString, pRO.AccountingEndDateString, pRO.GeleisteteFLSMitStundensatzAktuell * pRO.RateFactor);
2016-06-27 01:45:38 +02:00
}
else
{
2017-06-11 15:50:31 +02:00
pRO.Abrechnungstext3 = String.Format("{2:0.00} Fachleistungsstunden in der Zeit vom {0} - {1}",
pRO.AccountingStartDateString, pRO.AccountingEndDateString, pRO.GeleisteteFLSMitStundensatzAktuell * pRO.RateFactor);
2016-06-27 01:45:38 +02:00
}
this.bindingSource1.DataSource = pRO;
}
}
}