Beispiel #1
0
        public VoteStatisticsViewModel GetVoteOnResolutionStatisticsPercentage(string resolutionId)
        {
            VoteStatisticsViewModel voteStatisticsViewModel = new VoteStatisticsViewModel
            {
                VoteQuantity        = _context.GetVotesQuantity(resolutionId),
                ArrayWithStatistics = _context.GetPercentageQuantityOfConcreteOptions(resolutionId)
            };

            voteStatisticsViewModel.NoVoteQuantity = _context.GetNoVotesQuantity(voteStatisticsViewModel.VoteQuantity);

            return(voteStatisticsViewModel);
        }