Sha256: 06f3cca73ee8decb7461cf72c38b9148edb74117604332b456b9413a470771f1

Contents?: true

Size: 650 Bytes

Versions: 14

Compression:

Stored size: 650 Bytes

Contents

class <%= migration_name %> < ActiveRecord::Migration

  def self.up
    create_table :<%= admin_users_table_name %> do |t|
      t.string :first_name, :default => "", :null => false
      t.string :last_name, :default => "", :null => false
      t.string :role, :null => false
      t.string :email, :null => false
      t.boolean :status, :default => false
      t.string :token, :null => false
      t.string :password_digest, :null => false
      t.string :preferences
      t.timestamps
    end
    add_index :<%= admin_users_table_name %>, :email, :unique => true
  end

  def self.down
    drop_table :<%= admin_users_table_name %>
  end

end

Version data entries

14 entries across 14 versions & 2 rubygems

Version Path
brainsome_typus-4.0.0.beta13 lib/generators/templates/migration.erb
brainsome_typus-4.0.0.beta12 lib/generators/templates/migration.erb
brainsome_typus-4.0.0.beta11 lib/generators/templates/migration.erb
brainsome_typus-4.0.0.beta10 lib/generators/templates/migration.erb
brainsome_typus-4.0.0.beta9 lib/generators/templates/migration.erb
brainsome_typus-4.0.0.beta8 lib/generators/templates/migration.erb
brainsome_typus-4.0.0.beta7 lib/generators/templates/migration.erb
typus-rails4-4.0.0.beta6 lib/generators/templates/migration.erb
brainsome_typus-4.0.0.beta6 lib/generators/templates/migration.erb
brainsome_typus-4.0.0.beta5 lib/generators/templates/migration.erb
brainsome_typus-4.0.0.beta4 lib/generators/templates/migration.erb
brainsome_typus-4.0.0.beta3 lib/generators/templates/migration.erb
brainsome_typus-4.0.0.beta2 lib/generators/templates/migration.erb
brainsome_typus-4.0.0.beta1 lib/generators/templates/migration.erb