gab-social/db/migrate/20201127051074_create_chat_messages.rb
mgabdev 9a43c51085 Progress on dms, code cleanup
Progress on dms, code cleanup
2020-12-02 23:22:51 -05:00

15 lines
422 B
Ruby

class CreateChatMessages < ActiveRecord::Migration[5.2]
def change
create_table :chat_messages do |t|
t.text :text, null: false, default: ''
t.text :language, null: false, default: ''
t.integer :from_account_id, null: false
t.integer :chat_conversation_id, null: false
t.timestamps null: false
end
add_index :chat_messages, [:from_account_id, :chat_conversation_id]
end
end