added date of birth validation to PAS

This commit is contained in:
Daniel Schick 2023-05-24 09:37:48 +02:00
parent a89ef42258
commit 6df2c0224d

View File

@ -362,6 +362,9 @@ namespace bsmd.database
violations.Add(RuleEngine.CreateViolation(ValidationCode.IMPLAUSIBLE, "Gender set to unknown", null, this.Title, this.Identifier, this.Tablename)); violations.Add(RuleEngine.CreateViolation(ValidationCode.IMPLAUSIBLE, "Gender set to unknown", null, this.Title, this.Identifier, this.Tablename));
} }
if ((this.PassengerDateOfBirth.HasValue) && (this.PassengerDateOfBirth.Value > DateTime.Today))
violations.Add(RuleEngine.CreateViolation(ValidationCode.TIME_IMPLAUSIBLE, "Date of birth is in the future", null, this.Title, this.Identifier, this.Tablename));
} }
#endregion #endregion