So I've developed the model associations and a counter cache column as shown in the first answer here: Model association question
Now I want to know, after creating two buttons, one for upvote and downvote, as well as display the counter cache for the number of votes: <%= pluralize video.video_votes.size, 'vote' %>
how should I go about creating the controller method/s so that the vote count will be incremented by 1 or decreased by 1? I'm pretty sure I could figure out the AJAX part myself, so I'm primarily curious about initially doing this as a normal HTTP request. (Of course, I wouldn't mind help with the AJAX as well...)