Beispiel #1
0
        public async Task SaveAuthorityVote(AuthorityPollSaveViewModel model, string voterId)
        {
            var votes = model.Votes.Select(item => new Vote
            {
                PollId = model.PollId, VoterId = voterId, VotedUserId = item.UserId, Value = item.Value
            });

            await _voteService.AddVotes(votes);
        }