Implement forum topic voting and tag change pruning (#3580)

This commit is contained in:
Albert Yi
2018-04-16 16:09:39 -07:00
parent 45fad069d7
commit f2b525a6d2
182 changed files with 558 additions and 554 deletions

View File

@@ -0,0 +1,14 @@
class CreateForumPostVotes < ActiveRecord::Migration[5.1]
def change
create_table :forum_post_votes do |t|
t.integer :forum_post_id, null: false
t.integer :creator_id, null: false
t.integer :score, null: false
t.timestamps
end
add_index :forum_post_votes, :forum_post_id
add_index :forum_post_votes, [:forum_post_id, :creator_id], unique: true
end
end