Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/develop' into peggy/bceid-name
Browse files Browse the repository at this point in the history
  • Loading branch information
peggy-quartech committed Oct 29, 2024
2 parents 8ef090b + 34a95f8 commit f4f7fe7
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/Spd.Manager.Licence/ApplicantProfileValidation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ public ApplicantUpdateRequestValidator()
{
RuleFor(r => r.ApplicationTypeCode).NotEmpty().IsInEnum().When(r => r.LicenceId != null);
RuleFor(r => r.Surname).NotEmpty();
RuleFor(r => r.DateOfBirth).NotEmpty();
RuleFor(r => r.DateOfBirth).Must(d => d > new DateOnly(1800, 1, 1)).NotEmpty();
RuleFor(r => r.GenderCode).NotEmpty().IsInEnum();
RuleFor(r => r.PhoneNumber).MaximumLength(30).NotEmpty();
RuleFor(r => r.EmailAddress).MaximumLength(75).NotEmpty().EmailAddress();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public ControllingMemberCrcAppAnonymousSubmitRequestValidator()
RuleFor(r => r.GenderCode)
.NotNull()
.NotEmpty();
RuleFor(r => r.DateOfBirth).NotNull().NotEmpty();
RuleFor(r => r.DateOfBirth).Must(d => d > new DateOnly(1800, 1, 1)).NotNull().NotEmpty();
RuleFor(r => r.PhoneNumber)
.MaximumLength(30);
RuleFor(r => r.EmailAddress)
Expand Down
2 changes: 1 addition & 1 deletion src/Spd.Manager.Licence/LicenceAppValidation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ public PersonalLicenceAppBaseValidator()
RuleFor(r => r.ServiceTypeCode).NotEmpty();
RuleFor(r => r.ApplicationTypeCode).NotEmpty();
RuleFor(r => r.Surname).NotEmpty();
RuleFor(r => r.DateOfBirth).NotEmpty();
RuleFor(r => r.DateOfBirth).Must(d => d > new DateOnly(1800, 1, 1)).NotEmpty();
RuleFor(r => r.GenderCode).NotEmpty();
RuleFor(r => r.LicenceTermCode).NotEmpty();
RuleFor(r => r.HasExpiredLicence).NotEmpty();
Expand Down
1 change: 1 addition & 0 deletions src/Spd.Manager.Screening/ApplicationContract.cs
Original file line number Diff line number Diff line change
Expand Up @@ -594,6 +594,7 @@ public ApplicationCreateRequestValidator()
.NotEmpty();

RuleFor(r => r.DateOfBirth)
.Must(d => d > new DateOnly(1800, 1, 1))
.NotEmpty();

RuleFor(r => r.BirthPlace)
Expand Down

0 comments on commit f4f7fe7

Please sign in to comment.