add vote infra and ui prep for connection ui to backend
This commit is contained in:
@ -26,7 +26,8 @@ CREATE TABLE votes (
|
||||
comment_id TEXT, -- NULL if vote is on webpage
|
||||
voter TEXT NOT NULL,
|
||||
vote_type TEXT NOT NULL,
|
||||
created_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP
|
||||
created_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
UNIQUE (voter, comment_id, webpage_id) -- ensure a user can only vote once per comment or webpage
|
||||
);
|
||||
|
||||
-- make a table for storing users
|
||||
|
Reference in New Issue
Block a user