Generator Changes at 11/22/2025 9:58:16 PM +03:30

This commit is contained in:
masoodafar-web
2025-11-22 22:02:04 +03:30
parent fb9d2f6a9c
commit 56478c79c2
22 changed files with 281 additions and 31 deletions

View File

@@ -8,12 +8,14 @@ public record CreateNewUserOrderCommand : IRequest<CreateNewUserOrderResponseDto
//شناسه تراکنش
public long? TransactionId { get; init; }
//وضعیت پرداخت
public bool PaymentStatus { get; init; }
public PaymentStatus PaymentStatus { get; init; }
//تاریخ پرداخت
public DateTime? PaymentDate { get; init; }
//شناسه کاربر
public long UserId { get; init; }
//شناسه آدرس کاربر
public long UserAddressId { get; init; }
//
public PaymentMethod? PaymentMethod { get; init; }
}

View File

@@ -8,11 +8,14 @@ public class CreateNewUserOrderCommandValidator : AbstractValidator<CreateNewUse
RuleFor(model => model.PackageId)
.NotNull();
RuleFor(model => model.PaymentStatus)
.IsInEnum()
.NotNull();
RuleFor(model => model.UserId)
.NotNull();
RuleFor(model => model.UserAddressId)
.NotNull();
RuleFor(model => model.PaymentMethod)
.IsInEnum();
}
public Func<object, string, Task<IEnumerable<string>>> ValidateValue => async (model, propertyName) =>
{