This commit is contained in:
Alex Turchyn
2023-09-16 01:06:29 +03:00
parent b3662ddea8
commit ef618f8f49
14 changed files with 163 additions and 3 deletions
@@ -0,0 +1,9 @@
# frozen_string_literal: true
class AddDeviseTwoFactorToUsers < ActiveRecord::Migration[7.0]
def change
add_column :users, :otp_secret, :string
add_column :users, :consumed_timestep, :integer
add_column :users, :otp_required_for_login, :boolean, default: false, null: false
end
end
+4 -1
View File
@@ -10,7 +10,7 @@
#
# It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema[7.0].define(version: 2023_09_10_084410) do
ActiveRecord::Schema[7.0].define(version: 2023_09_15_200635) do
# These are extensions that must be enabled in order to support this database
enable_extension "plpgsql"
@@ -177,6 +177,9 @@ ActiveRecord::Schema[7.0].define(version: 2023_09_10_084410) do
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.text "uuid", null: false
t.string "otp_secret"
t.integer "consumed_timestep"
t.boolean "otp_required_for_login", default: false, null: false
t.index ["account_id"], name: "index_users_on_account_id"
t.index ["email"], name: "index_users_on_email", unique: true
t.index ["reset_password_token"], name: "index_users_on_reset_password_token", unique: true