demarches-normaliennes/db/migrate/20150804131511_create_commentaires.rb
2015-08-10 11:05:06 +02:00

13 lines
306 B
Ruby

class CreateCommentaires < ActiveRecord::Migration
def change
create_table :commentaires do |t|
t.string :email
t.date :created_at
t.string :body
t.references :dossier, index: true
t.timestamps null: false
end
add_foreign_key :commentaires, :dossiers
end
end