Sha256: 605a25992e68e12130facfeabb97eb6297c603329ef6cc381a84b2961d7c29f4

Contents?: true

Size: 304 Bytes

Versions: 1

Compression:

Stored size: 304 Bytes

Contents

class CreateCategories < ActiveRecord::Migration
  def change
    create_table :categories do |t|
      t.references  :project, null: false
      t.foreign_key :projects
      t.string      :name
      t.timestamps
    end

    add_index :categories, :id
    add_index :categories, :project_id
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
self_systeem-0.1.0 test/dummy_app/db/migrate/20140312212057_create_categories.rb