Created
September 10, 2019 02:06
-
-
Save ParthivPatel-BTC/d9f192b1e16d8dbfae44d089b72a9687 to your computer and use it in GitHub Desktop.
Migrations - Add tasks table
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class CreateTasks < ActiveRecord::Migration[5.2] | |
def change | |
create_table :tasks do |t| | |
t.string :title | |
t.string :description | |
t.datetime :start_date | |
t.datetime :end_date | |
t.string :event | |
t.string :members | |
t.references :user, foreign_key: true | |
t.timestamps | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment