Sha256: 97da7989c80fd446e9aa19c471360f019b4e8e9bcf211f977b55b7869ca7b48d

Contents?: true

Size: 484 Bytes

Versions: 10

Compression:

Stored size: 484 Bytes

Contents

class DeviseAuthyAddTo<%= table_name.camelize %> < ActiveRecord::Migration<%= migration_version %>
  def self.up
    change_table :<%= table_name %> do |t|
      t.string    :authy_id
      t.datetime  :last_sign_in_with_authy
      t.boolean   :authy_enabled, :default => false
    end

    add_index :<%= table_name %>, :authy_id
  end

  def self.down
    change_table :<%= table_name %> do |t|
      t.remove :authy_id, :last_sign_in_with_authy, :authy_enabled
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
devise-authy-2.3.1 lib/generators/active_record/templates/migration.rb
devise-authy-2.3.0 lib/generators/active_record/templates/migration.rb
devise-authy-2.2.1 lib/generators/active_record/templates/migration.rb
devise-authy-2.2.0 lib/generators/active_record/templates/migration.rb
devise-authy-2.1.0 lib/generators/active_record/templates/migration.rb
devise-authy-2.0.0 lib/generators/active_record/templates/migration.rb
devise-authy-1.11.1 lib/generators/active_record/templates/migration.rb
devise-authy-1.11.0 lib/generators/active_record/templates/migration.rb
devise-authy-1.10.0 lib/generators/active_record/templates/migration.rb
devise-authy-1.9.0 lib/generators/active_record/templates/migration.rb