Create emoji reactions table

This commit is contained in:
KMY 2023-02-23 09:14:38 +09:00
parent 87f2d18462
commit 0ebf8b302d
4 changed files with 78 additions and 1 deletions

View file

@ -0,0 +1,13 @@
class CreateEmojiReactions < ActiveRecord::Migration[6.1]
def change
create_table :emoji_reactions do |t|
t.belongs_to :account, null: false, foreign_key: { on_delete: :cascade }, index: false
t.belongs_to :status, null: false, foreign_key: { on_delete: :cascade }
t.string :name, null: false, default: ''
t.belongs_to :custom_emoji, foreign_key: { on_delete: :cascade }, index: false
t.string :uri
end
end
end