scinote-web/db/migrate/20170207100731_add_state_to_tasks.rb
2017-02-10 14:27:20 +01:00

19 lines
405 B
Ruby

class AddStateToTasks < ActiveRecord::Migration
def up
add_column :my_modules,
:state,
:integer,
limit: 1,
default: 0
add_column :my_modules,
:completed_on,
:datetime,
null: true
end
def down
remove_column :my_modules, :state
remove_column :my_modules, :completed_on
end
end