Sha256: 86b0990c3dae682ea12e5539981a4fe7fa66a018d40a694e1bfff32f9c6f1659

Contents?: true

Size: 493 Bytes

Versions: 17

Compression:

Stored size: 493 Bytes

Contents

class CreateSafePosts < ActiveRecord::Migration[5.1]
  def change
    create_table :safe_posts do |t|
      t.string :title, null: false
      t.text :body, null: false
      t.integer :author_id, null: false
      t.boolean :enabled, default: false
      t.datetime :live_at
      t.datetime :deleted_at

      t.timestamps
    end

    add_index :safe_posts, :author_id
    add_index :safe_posts, :enabled
    add_index :safe_posts, :live_at
    add_index :safe_posts, :deleted_at
  end
end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
historiographer-4.1.0 /Users/brettshollenberger/programming/historiographer/spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-4.0.0 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-3.1.2 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-3.1.1 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-3.1.0 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-3.0.0 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-2.0.1 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-2.0.0 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-1.4.3 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-1.4.1 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-1.4.0 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-1.3.1 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-1.3.0 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-1.2.0 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-1.1.0 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-1.0.2 spec/db/migrate/20171011194624_create_safe_posts.rb
historiographer-1.0.0 spec/db/migrate/20171011194624_create_safe_posts.rb