Generator Changes at 9/28/2025 6:19:21 AM

This commit is contained in:
MeysamMoghaddam
2025-09-28 06:30:13 +03:30
parent 1a99a88552
commit a3b7302d90
16 changed files with 534 additions and 6 deletions

View File

@@ -11,5 +11,9 @@ public record UpdateUserCommand : IRequest<Unit>
public string? NationalCode { get; init; }
//آدرس آواتار
public string? AvatarPath { get; init; }
//قوانین پذیرفته شده؟
public bool IsRulesAccepted { get; init; }
//تاریخ پذیرش قوانین
public DateTime? RulesAcceptedAt { get; init; }
}

View File

@@ -5,6 +5,8 @@ public class UpdateUserCommandValidator : AbstractValidator<UpdateUserCommand>
{
RuleFor(model => model.Id)
.NotNull();
RuleFor(model => model.IsRulesAccepted)
.NotNull();
}
public Func<object, string, Task<IEnumerable<string>>> ValidateValue => async (model, propertyName) =>
{