Sha256: 90f1e22976726c65fbdde1c67873f63ed459d528b6ca6108d89728b94695b0f7

Contents?: true

Size: 539 Bytes

Versions: 4

Compression:

Stored size: 539 Bytes

Contents

require 'active_support/core_ext'

class CreateUsersAndIdentities < ActiveRecord::Migration
  def self.up
    create_table :users do |t|
      t.string :name, :null => false
      #Any additional fields here
      t.timestamps
    end

    create_table :identities do |t|
      t.integer    :user_id,      :null => false
      t.string     :provider,     :null => false
      t.string     :value,        :null => false
      t.text       :data
      t.timestamps
    end
  end

  def self.down
    drop_table :identities, :users
  end
end

Version data entries

4 entries across 2 versions & 1 rubygems

Version Path
billfold-1.0.1 lib/rails/generators/billfold/templates/migration.rb
billfold-1.0.1 spec/dummy/db/migrate/20110904204023_create_users_and_identities.rb
billfold-1.0.0 lib/rails/generators/billfold/templates/migration.rb
billfold-1.0.0 spec/dummy/db/migrate/20110904204023_create_users_and_identities.rb