LebenshilfeStade/Service/CustomServiceRecordValidator.cs - Anpassung auf deren Leistungsnamen
SupportOID=164787
This commit is contained in:
@@ -49,7 +49,7 @@ namespace LebenshilfeStade.Service
|
||||
var now = newServiceRecord.Start ?? DateTime.Now;
|
||||
var since90Days = now.AddDays(-90);
|
||||
var recentRecords = DAOFactory.SearchDAO.FindServiceRecordsDetailsForLastDaysWithStartEndDate(fehlkontaktCb2ScOid.Value, since90Days, now);
|
||||
int fehlkontaktCount = recentRecords.Count(r => r.ServiceDescription?.Name == "Fehlkontakt" && r.Oid != newServiceRecord.ServiceRecordOid);
|
||||
int fehlkontaktCount = recentRecords.Count(r => r.ServiceDescription?.Name.Contains("Fehlb") == true && r.Oid != newServiceRecord.ServiceRecordOid);
|
||||
if (fehlkontaktCount >= 3)
|
||||
{
|
||||
validation.Add(new ServiceRecordValidationResultDC
|
||||
|
||||
Reference in New Issue
Block a user