feat: Implement customer profile and referral queries
- Add GetCustomerProfileResponseDto for retrieving customer profile information. - Create GetCustomerReferralsQuery and GetCustomerReferralsQueryHandler to fetch customer referrals with pagination and filtering options. - Introduce GetCustomerReferralsResponseDto to structure the response for customer referrals. - Implement GetCustomerSettingsQuery and GetCustomerSettingsQueryHandler to retrieve user settings. - Add GetCustomerOrder and GetCustomerOrderQueryHandler for fetching specific customer orders. - Create GetCustomerOrderHistoryQuery and GetCustomerOrderHistoryQueryHandler to retrieve order history with filtering options. - Implement GetCustomerOrdersQuery and GetCustomerOrdersQueryHandler for fetching multiple customer orders with filters. - Add GetCustomerWalletChangeLogQuery and GetCustomerWalletChangeLogQueryHandler for retrieving wallet change logs. - Implement GetCustomerWithdrawalSettingsQuery and GetCustomerWithdrawalSettingsQueryHandler for fetching withdrawal settings. - Create GetCustomerWithdrawalsQuery and GetCustomerWithdrawalsQueryHandler to retrieve customer withdrawal requests.
This commit is contained in:
+3
-3
@@ -21,7 +21,7 @@ public class VerifyOtpTokenCommandHandler : IRequestHandler<VerifyOtpTokenComman
|
||||
.FirstOrDefaultAsync(cancellationToken);
|
||||
|
||||
if (otpToken == null || !otpToken.IsValid(request.Code))
|
||||
return new VerifyOtpTokenResponseDto { IsSuccess = false, Message = "کد تایید نامعتبر است" };
|
||||
return new VerifyOtpTokenResponseDto { Success = false, Message = "کد تایید نامعتبر است" };
|
||||
|
||||
var user = await _context.Users
|
||||
.Include(u => u.UserContracts)
|
||||
@@ -33,7 +33,7 @@ public class VerifyOtpTokenCommandHandler : IRequestHandler<VerifyOtpTokenComman
|
||||
.FirstOrDefaultAsync(cancellationToken);
|
||||
|
||||
if (user == null)
|
||||
return new VerifyOtpTokenResponseDto { IsSuccess = false, Message = "کاربر یافت نشد" };
|
||||
return new VerifyOtpTokenResponseDto { Success = false, Message = "کاربر یافت نشد" };
|
||||
|
||||
// Mark OTP as used
|
||||
otpToken.IsUsed = true;
|
||||
@@ -44,7 +44,7 @@ public class VerifyOtpTokenCommandHandler : IRequestHandler<VerifyOtpTokenComman
|
||||
|
||||
return new VerifyOtpTokenResponseDto
|
||||
{
|
||||
IsSuccess = true,
|
||||
Success = true,
|
||||
Message = "کد تایید با موفقیت تایید شد",
|
||||
Token = token
|
||||
};
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@ namespace CMSMicroservice.Application.UserCQ.Commands.VerifyOtpToken;
|
||||
public class VerifyOtpTokenResponseDto
|
||||
{
|
||||
//موفق؟
|
||||
public bool IsSuccess { get; set; }
|
||||
public bool Success { get; set; }
|
||||
//پیام
|
||||
public string Message { get; set; }
|
||||
//توکن
|
||||
|
||||
Reference in New Issue
Block a user