Example #1
0
            public async Task <IResult> Handle(UpdateUserClaimCommand request, CancellationToken cancellationToken)
            {
                var userList = request.ClaimId.Select(x => new UserClaim()
                {
                    ClaimId = x, UserId = request.UserId
                });

                await _userClaimRepository.BulkInsert(request.UserId, userList);

                await _userClaimRepository.SaveChangesAsync();

                return(new SuccessResult(Messages.UserClaimUpdated));
            }