This commit is contained in:
2018-11-11 10:12:43 -06:00
parent 8a7b3d8ae0
commit 869a9fc048
16 changed files with 412 additions and 13 deletions

View File

@ -0,0 +1,15 @@
# frozen_string_literal: true
class CreateBlogs < ActiveRecord::Migration[5.2]
def change
create_table :blogs do |t|
t.string :title, null: false
t.text :article, null: false
t.string :published_date, null: false, default: ""
t.integer :user_id
t.timestamps
end
add_index :blogs, :user_id
end
end