add migration for User organization fields

This commit is contained in:
kikito
2015-08-11 18:57:16 +02:00
parent 8053034ddf
commit 3551b55bdd
2 changed files with 19 additions and 9 deletions

View File

@@ -0,0 +1,7 @@
class AddOrganizationToUsers < ActiveRecord::Migration
def change
add_column :users, :organization_name, :string, limit: 80
add_column :users, :organization_verified_at, :datetime
add_column :users, :phone_number, :string, limit: 30
end
end

View File

@@ -11,7 +11,7 @@
#
# It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema.define(version: 20150807140346) do
ActiveRecord::Schema.define(version: 20150810155304) do
# These are extensions that must be enabled in order to support this database
enable_extension "plpgsql"
@@ -74,18 +74,18 @@ ActiveRecord::Schema.define(version: 20150807140346) do
add_index "tags", ["name"], name: "index_tags_on_name", unique: true, using: :btree
create_table "users", force: :cascade do |t|
t.string "email", default: "", null: false
t.string "encrypted_password", default: "", null: false
t.string "email", default: "", null: false
t.string "encrypted_password", default: "", null: false
t.string "reset_password_token"
t.datetime "reset_password_sent_at"
t.datetime "remember_created_at"
t.integer "sign_in_count", default: 0, null: false
t.integer "sign_in_count", default: 0, null: false
t.datetime "current_sign_in_at"
t.datetime "last_sign_in_at"
t.string "current_sign_in_ip"
t.string "last_sign_in_ip"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.string "first_name"
t.string "last_name"
t.string "confirmation_token"
@@ -93,9 +93,12 @@ ActiveRecord::Schema.define(version: 20150807140346) do
t.datetime "confirmation_sent_at"
t.string "unconfirmed_email"
t.string "nickname"
t.boolean "use_nickname", default: false, null: false
t.boolean "email_on_debate_comment", default: false
t.boolean "email_on_comment_reply", default: false
t.boolean "use_nickname", default: false, null: false
t.boolean "email_on_debate_comment", default: false
t.boolean "email_on_comment_reply", default: false
t.string "organization_name", limit: 80
t.datetime "organization_verified_at"
t.string "phone_number", limit: 30
end
add_index "users", ["confirmation_token"], name: "index_users_on_confirmation_token", unique: true, using: :btree