Files
BackOffice.BFF/src/BackOffice.BFF.Application/CommissionCQ/Queries/GetUserPayouts/GetUserPayoutsQueryValidator.cs
T
masoodafar-web de0daa5f61
Build and Deploy / build (push) Successful in 2m30s
fix: update commission payout mapping and handle null Created date
2025-12-14 01:28:46 +03:30

25 lines
985 B
C#

namespace BackOffice.BFF.Application.CommissionCQ.Queries.GetUserPayouts;
public class GetUserPayoutsQueryValidator : AbstractValidator<GetUserPayoutsQuery>
{
public GetUserPayoutsQueryValidator()
{
// RuleFor(x => x.PaginationState)
// .NotNull()
// .WithMessage("موقعیت صفحه‌بندی الزامی است");
//
// When(x => x.Filter != null, () =>
// {
// RuleFor(x => x.Filter!.UserId)
// .GreaterThan(0)
// .When(x => x.Filter!.UserId.HasValue)
// .WithMessage("شناسه کاربر معتبر نیست");
//
// RuleFor(x => x.Filter!.WeekNumber)
// .Matches(@"^\d{4}-W\d{2}$")
// .When(x => !string.IsNullOrWhiteSpace(x.Filter!.WeekNumber))
// .WithMessage("فرمت شماره هفته باید به صورت YYYY-Www باشد (مثال: 2025-W48)");
// });
}
}