fix: update commission payout mapping and handle null Created date
Build and Deploy / build (push) Successful in 2m30s

This commit is contained in:
masoodafar-web
2025-12-14 01:28:46 +03:30
parent c6abee2650
commit de0daa5f61
3 changed files with 38 additions and 17 deletions
@@ -12,6 +12,27 @@ public class CommissionProfile : IRegister
{
void IRegister.Register(TypeAdapterConfig config)
{
// GetUserCommissionPayoutsRequest -> GetUserPayoutsQuery
config.NewConfig<GetUserCommissionPayoutsRequest, GetUserPayoutsQuery>()
.MapWith(src => new GetUserPayoutsQuery
{
PaginationState = src.PaginationState != null
? new BackOffice.BFF.Application.Common.Models.PaginationState
{
PageNumber = src.PaginationState.PageNumber,
PageSize = src.PaginationState.PageSize
}
: null,
Filter = src.Filter != null
? new BackOffice.BFF.Application.CommissionCQ.Queries.GetUserPayouts.GetUserPayoutsFilter
{
UserId = src.Filter.UserId,
WeekNumber = src.Filter.WeekNumber,
Status = src.Filter.Status
}
: null
});
// GetWeeklyPoolResponseDto -> GetWeeklyCommissionPoolResponse
config.NewConfig<GetWeeklyPoolResponseDto, GetWeeklyCommissionPoolResponse>()
.MapWith(src => new GetWeeklyCommissionPoolResponse