public int PollVote(List <int> voteIds, int pollId) { if (voteIds != null) { foreach (var voteId in voteIds) { var answer = _pollAnswerService.GetById(voteId); if (answer != null) { _pollAnswerService.IncreaseVote(answer); } } var cookieName = string.Format(EzCMSContants.VotedUserCookie, pollId); StateManager.GetCookie(cookieName, true, true, DateTime.Now.AddDays(EzCMSContants.PollCookieExpireDay)); return(voteIds.Count); } return(0); }