Class: AddInputMaskAttributesToAnswer

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

Class Method Summary collapse

Class Method Details

.downObject



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

def self.down
  remove_column :answers, :input_mask
  remove_column :answers, :input_mask_placeholder
end

.upObject



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

def self.up
  add_column :answers, :input_mask, :string
  add_column :answers, :input_mask_placeholder, :string
end