tiss2go/db/migrate/20200529081537_create_favorite_projects.rb
2020-06-04 21:51:52 +02:00

14 lines
346 B
Ruby

class CreateFavoriteProjects < ActiveRecord::Migration[6.0]
def change
create_table :favorite_projects, id: false do |t|
t.integer :id, null: false
t.integer :user_id, null: false
t.string :title
t.string :personal_annotation
t.timestamps
end
add_index :favorite_projects, :id, unique: true
end
end