Sha256: 40e6adecc76ca05fd2d954fc18855cb764120bef99c899e790c45be9942971a9

Contents?: true

Size: 288 Bytes

Versions: 29

Compression:

Stored size: 288 Bytes

Contents

class AddAdminFlagStrategy < ActiveRecord::Migration

  def self.up           
    change_table :<%= table_name %> do |t|
      t.boolean :admin_flag, :default => false
    end
  end

  def self.down
    change_table :<%= table_name %> do |t|
      t.remove :admin_flag
    end
  end
end

Version data entries

29 entries across 29 versions & 1 rubygems

Version Path
roles_active_record-0.5.1 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.5.0 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.4.9 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.4.8 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.4.7 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.4.6.4 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.4.6.3 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.4.6.2 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.4.6.1 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.4.6 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.4.5 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.4.4 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.4.3 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.4.2 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.4.1 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.4.0 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.3.6 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.3.5 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.3.4 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb
roles_active_record-0.3.3 lib/generators/active_record/roles_migration/templates/add_admin_flag_strategy.erb