From 7f481afdd8425b6771451b1fe3ac2b956adce6b4 Mon Sep 17 00:00:00 2001 From: Koen Bolhuis Date: Tue, 9 Oct 2018 21:45:26 +0200 Subject: [PATCH] Add voting javascript (doesn't do anything yet) --- .../postings/templates/postings/frontend/entity.html | 1 + frontpage/rateables/js/voting.js | 10 ++++++++++ 2 files changed, 11 insertions(+) create mode 100644 frontpage/rateables/js/voting.js diff --git a/backend/postings/templates/postings/frontend/entity.html b/backend/postings/templates/postings/frontend/entity.html index 2545745..1db3136 100644 --- a/backend/postings/templates/postings/frontend/entity.html +++ b/backend/postings/templates/postings/frontend/entity.html @@ -193,5 +193,6 @@ + \ No newline at end of file diff --git a/frontpage/rateables/js/voting.js b/frontpage/rateables/js/voting.js new file mode 100644 index 0000000..f2a3c41 --- /dev/null +++ b/frontpage/rateables/js/voting.js @@ -0,0 +1,10 @@ +$(function() { + $(".vote-up").click(function() { + var review = $(this).attr("data-review-id"); + // Vote up + }); + $(".vote-down").click(function() { + var review = $(this).attr("data-review-id"); + // Vote down + }); +}); \ No newline at end of file