Commit 7fa023162391fbd2c86de75c0c0c90f5e33c6416
1 parent
6505c02e
Exists in
theme-brasil-digital-from-staging
and in
9 other branches
api: renaming private token migration
Showing
3 changed files
with
21 additions
and
19 deletions
Show diff stats
db/migrate/20140407013817_add_private_token_info_to_users.rb
| ... | ... | @@ -1,11 +0,0 @@ |
| 1 | -class AddPrivateTokenInfoToUsers < ActiveRecord::Migration | |
| 2 | - def self.up | |
| 3 | - add_column :users, :private_token, :string | |
| 4 | - add_column :users, :private_token_generated_at, :datetime | |
| 5 | - end | |
| 6 | - | |
| 7 | - def self.down | |
| 8 | - remove_column :users, :private_token | |
| 9 | - remove_column :users, :private_token_generated_at | |
| 10 | - end | |
| 11 | -end |
db/migrate/20150223180807_add_private_token_info_to_users.rb
0 → 100644
| ... | ... | @@ -0,0 +1,11 @@ |
| 1 | +class AddPrivateTokenInfoToUsers < ActiveRecord::Migration | |
| 2 | + def self.up | |
| 3 | + add_column :users, :private_token, :string | |
| 4 | + add_column :users, :private_token_generated_at, :datetime | |
| 5 | + end | |
| 6 | + | |
| 7 | + def self.down | |
| 8 | + remove_column :users, :private_token | |
| 9 | + remove_column :users, :private_token_generated_at | |
| 10 | + end | |
| 11 | +end | ... | ... |
db/schema.rb
| ... | ... | @@ -11,7 +11,7 @@ |
| 11 | 11 | # |
| 12 | 12 | # It's strongly recommended to check this file into your version control system. |
| 13 | 13 | |
| 14 | -ActiveRecord::Schema.define(:version => 20150223180806) do | |
| 14 | +ActiveRecord::Schema.define(:version => 20150223180807) do | |
| 15 | 15 | |
| 16 | 16 | create_table "abuse_reports", :force => true do |t| |
| 17 | 17 | t.integer "reporter_id" |
| ... | ... | @@ -719,24 +719,26 @@ ActiveRecord::Schema.define(:version => 20150223180806) do |
| 719 | 719 | create_table "users", :force => true do |t| |
| 720 | 720 | t.string "login" |
| 721 | 721 | t.string "email" |
| 722 | - t.string "crypted_password", :limit => 40 | |
| 723 | - t.string "salt", :limit => 40 | |
| 722 | + t.string "crypted_password", :limit => 40 | |
| 723 | + t.string "salt", :limit => 40 | |
| 724 | 724 | t.datetime "created_at" |
| 725 | 725 | t.datetime "updated_at" |
| 726 | 726 | t.string "remember_token" |
| 727 | 727 | t.datetime "remember_token_expires_at" |
| 728 | 728 | t.text "terms_of_use" |
| 729 | - t.string "terms_accepted", :limit => 1 | |
| 729 | + t.string "terms_accepted", :limit => 1 | |
| 730 | 730 | t.integer "environment_id" |
| 731 | 731 | t.string "password_type" |
| 732 | - t.boolean "enable_email", :default => false | |
| 733 | - t.string "last_chat_status", :default => "" | |
| 734 | - t.string "chat_status", :default => "" | |
| 732 | + t.boolean "enable_email", :default => false | |
| 733 | + t.string "last_chat_status", :default => "" | |
| 734 | + t.string "chat_status", :default => "" | |
| 735 | 735 | t.datetime "chat_status_at" |
| 736 | - t.string "activation_code", :limit => 40 | |
| 736 | + t.string "activation_code", :limit => 40 | |
| 737 | 737 | t.datetime "activated_at" |
| 738 | 738 | t.string "return_to" |
| 739 | 739 | t.datetime "last_login_at" |
| 740 | + t.string "private_token" | |
| 741 | + t.datetime "private_token_generated_at" | |
| 740 | 742 | end |
| 741 | 743 | |
| 742 | 744 | create_table "validation_infos", :force => true do |t| | ... | ... |