OpenProject is the leading open source project management software.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
openproject/db/migrate/20160331190036_change_defau...

11 lines
393 B

class ChangeDefaultChannel < ActiveRecord::Migration
def self.up
change_column_default(:users, :default_otp_channel, 'sms')
User.where(default_otp_channel: 'text').update_all(default_otp_channel: 'sms')
end
def self.down
change_column_default(:users, :default_otp_channel, 'text')
User.where(default_otp_channel: 'sms').update_all(default_otp_channel: 'text')
end
end