Beispiel #1
0
 public void Put(WorkingCommentVoteUpdateRequest model)
 {
     DataProvider.ExecuteNonQuery("dbo.Comments_WorkingCommentVote",
                                  inputParamMapper : delegate(SqlParameterCollection paramCollection)
     {
         paramCollection.AddWithValue("@UpVote", model.UpVote);
         paramCollection.AddWithValue("@DownVote", model.DownVote);
         paramCollection.AddWithValue("@UserBaseId", model.UserBaseId);
         paramCollection.AddWithValue("@CommentId", model.CommentId);
         paramCollection.AddWithValue("@Action", model.Action);
     });
 }
Beispiel #2
0
        public IHttpActionResult Put(WorkingCommentVoteUpdateRequest model)
        {
            try
            {
                _workingCommentVoteService.Put(model); // change

                return(Ok(new SuccessResponse()));
            }
            catch (Exception ex)
            {
                return(BadRequest(ex.Message));
            }
        }