Phase 2 CTs implementation and tests, with config parameter

This commit is contained in:
Matt Amos 2011-03-22 10:26:10 +00:00 committed by Tom Hughes
parent 82db7eccc8
commit 8b12abd5bb
11 changed files with 102 additions and 15 deletions

View file

@ -0,0 +1,13 @@
class AddTermsSeenToUser < ActiveRecord::Migration
def self.up
add_column :users, :terms_seen, :boolean, :null => false, :default => false
# best guess available is just that everyone who has agreed has
# seen the terms, and that noone else has.
User.update_all "terms_seen = (terms_agreed is not null)"
end
def self.down
remove_column :users, :terms_seen
end
end