refactor(mappings): update filter mappings for club membership and payment transaction profiles
Build and Deploy to Kubernetes / build-and-deploy (push) Has been cancelled
Build and Deploy to Kubernetes / build-and-deploy (push) Has been cancelled
- Renamed filter types in ClubMembershipCycleHistoryProfile, ClubMembershipCycleProfile, PaymentTransactionProfile, UserPackagePurchaseProfile to improve clarity and consistency. - Adjusted mapping methods to utilize new filter type aliases for better readability and maintainability. - Ensured all relevant profiles are aligned with the updated filter structures.
This commit is contained in:
@@ -3,6 +3,8 @@ using CMSMicroservice.Application.PaymentTransactionCQ.Queries.GetPaymentTransac
|
||||
using CMSMicroservice.Protobuf.Protos.PaymentTransaction;
|
||||
using Google.Protobuf.WellKnownTypes;
|
||||
using Mapster;
|
||||
using AppFilter = CMSMicroservice.Application.PaymentTransactionCQ.Queries.GetAllPaymentTransactionByFilter.GetAllPaymentTransactionByFilterFilter;
|
||||
using ProtoFilter = CMSMicroservice.Protobuf.Protos.PaymentTransaction.GetAllPaymentTransactionByFilterFilter;
|
||||
|
||||
namespace CMSMicroservice.WebApi.Common.Mappings;
|
||||
|
||||
@@ -47,10 +49,10 @@ public class PaymentTransactionProfile : IRegister
|
||||
Models = { src.Models?.Select(MapModel) ?? [] }
|
||||
};
|
||||
|
||||
private static GetAllPaymentTransactionByFilterFilter? MapFilter(GetAllPaymentTransactionByFilterFilter? src)
|
||||
private static AppFilter? MapFilter(ProtoFilter? src)
|
||||
{
|
||||
if (src == null) return null;
|
||||
return new GetAllPaymentTransactionByFilterFilter
|
||||
return new AppFilter
|
||||
{
|
||||
UserId = src.HasUserId ? src.UserId : null,
|
||||
Mobile = src.HasMobile ? src.Mobile : null,
|
||||
|
||||
Reference in New Issue
Block a user