Class: AddApiIdsToResponseSetsAndResponses

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

Class Method Summary collapse

Class Method Details

.downObject



8
9
10
11
# File 'lib/generators/surveyor/templates/db/migrate/add_api_ids_to_response_sets_and_responses.rb', line 8

def self.down
  remove_column :response_sets, :api_id
  remove_column :responses, :api_id
end

.upObject



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

def self.up
  add_column :response_sets, :api_id, :string
  add_column :responses, :api_id, :string
end