diff --git a/ReportImp/BetreutesWohnenWoellReports/SettlementReport2.cs b/ReportImp/BetreutesWohnenWoellReports/SettlementReport2.cs index 1c13c502d..dbf704e5e 100644 --- a/ReportImp/BetreutesWohnenWoellReports/SettlementReport2.cs +++ b/ReportImp/BetreutesWohnenWoellReports/SettlementReport2.cs @@ -19,6 +19,7 @@ namespace BeWo.BetreutesWohnenWoellReports public void SetReportDataSource(Settlement2RO pRO) { decimal rateFactor = 1; + bool assistenzRechnung = false; foreach (var ii in pRO.InvoiceItems) { @@ -31,14 +32,16 @@ namespace BeWo.BetreutesWohnenWoellReports if (!pRO.FehlkontakteString.IsNullOrEmpty() && ii.RateFactor == 0) { GroupFooter2.Visible = true; - //if (!ii.ItemDescription.IsNullOrEmpty()) - //{ - //ii.AbrechnungsText = Regex.Replace(ii.DetailDescription, ii.ItemDescription, "Fehlkontakte"); - //} ii.AbrechnungsText = ii.AbrechnungsText.Replace("FLS", "Std."); ii.ItemDescription = "Fehlkontakte"; } - else if (ii.ItemDescription.IsNullOrEmpty()) + else if (ii.ItemDescription != null && ii.ItemDescription.ToLower().StartsWith("assistenz")) + { + assistenzRechnung = true; + ii.AbrechnungsText = ii.AbrechnungsText.Replace("FLS", "ASS"); + ii.ItemDescription = "Assistenzstunden"; + } + else { ii.ItemDescription = "Fachleistungsstunden"; } @@ -46,6 +49,15 @@ namespace BeWo.BetreutesWohnenWoellReports pRO.RateFactor = (double)rateFactor; this.Zwischensumme.DataSource = pRO; + + if (assistenzRechnung) + { + xrTableCell4.Text = "Bewilligte Assistenzstunden(ASS) gesamt:"; + if (pRO.ApprovedFLS != null) + { + pRO.ApprovedFLS = pRO.ApprovedFLS.Replace("FLS", "ASS"); + } + } } } }