Class: DropUniqueIndexOnAccessCodeInSurveys

Inherits:
ActiveRecord::Migration
  • Object
show all
Defined in:
lib/generators/surveyor/templates/db/migrate/drop_unique_index_on_access_code_in_surveys.rb

Class Method Summary collapse

Class Method Details

.downObject



7
8
9
# File 'lib/generators/surveyor/templates/db/migrate/drop_unique_index_on_access_code_in_surveys.rb', line 7

def self.down
  add_index(:surveys, :access_code, :name => 'surveys_ac_idx')
end

.upObject



3
4
5
# File 'lib/generators/surveyor/templates/db/migrate/drop_unique_index_on_access_code_in_surveys.rb', line 3

def self.up
  remove_index( :surveys, :name => 'surveys_ac_idx' )
end