This commit is contained in:
King
2025-09-28 18:54:22 +03:30
parent 9fcc5d9276
commit ad492abdea
28 changed files with 160 additions and 58 deletions
@@ -1,3 +1,6 @@
using BackOffice.BFF.Application.UserCQ.Commands.CreateNewUser;
using CMSMicroservice.Protobuf.Protos.UserAddress;
namespace BackOffice.BFF.Application.UserAddressCQ.Commands.CreateNewUserAddress;
public class CreateNewUserAddressCommandHandler : IRequestHandler<CreateNewUserAddressCommand, CreateNewUserAddressResponseDto>
{
@@ -10,7 +13,8 @@ public class CreateNewUserAddressCommandHandler : IRequestHandler<CreateNewUserA
public async Task<CreateNewUserAddressResponseDto> Handle(CreateNewUserAddressCommand request, CancellationToken cancellationToken)
{
//TODO: Implement your business logic
return new CreateNewUserAddressResponseDto();
var response = await _context.UserAddress.CreateNewUserAddressAsync(request.Adapt<CreateNewUserAddressRequest>(), cancellationToken: cancellationToken);
return response.Adapt<CreateNewUserAddressResponseDto>();
}
}