Ejemplo n.º 1
0
        public void Vote(SuggestionVoteModel vote)
        {
            var userId = UserId;

            if (_suggestionService.UserHasVoted(userId, vote.SuggestionId))
            {
                return;
            }
            _suggestionService.Vote(vote.SuggestionId, vote.UpVote, userId);
        }
Ejemplo n.º 2
0
 public ResponseResource Post(VoteOnSuggestionsRequest request)
 {
     return(_service.Vote(User, request));
 }
 public HttpResponseMessage Post(VoteOnSuggestionsRequest request)
 {
     return(Request.CreateResponse(HttpStatusCode.OK, _service.Vote(User, request)));
 }