2019-05-03 08:17:27 +10:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2014-02-25 14:30:49 +11:00
|
|
|
class SingleSignOnRecord < ActiveRecord::Base
|
|
|
|
belongs_to :user
|
2017-11-30 15:15:52 +08:00
|
|
|
|
|
|
|
validates :external_id, uniqueness: true
|
2014-02-25 14:30:49 +11:00
|
|
|
end
|
2014-03-20 15:35:51 +11:00
|
|
|
|
|
|
|
# == Schema Information
|
|
|
|
#
|
|
|
|
# Table name: single_sign_on_records
|
|
|
|
#
|
2018-05-09 07:49:50 +08:00
|
|
|
# id :integer not null, primary key
|
|
|
|
# user_id :integer not null
|
2019-01-11 14:29:56 -05:00
|
|
|
# external_id :string not null
|
2018-05-09 07:49:50 +08:00
|
|
|
# last_payload :text not null
|
|
|
|
# created_at :datetime not null
|
|
|
|
# updated_at :datetime not null
|
2019-01-11 14:29:56 -05:00
|
|
|
# external_username :string
|
|
|
|
# external_email :string
|
|
|
|
# external_name :string
|
2024-09-13 01:08:01 +02:00
|
|
|
# external_avatar_url :string(2000)
|
2018-05-09 07:49:50 +08:00
|
|
|
# external_profile_background_url :string
|
|
|
|
# external_card_background_url :string
|
2014-03-20 15:35:51 +11:00
|
|
|
#
|
|
|
|
# Indexes
|
|
|
|
#
|
|
|
|
# index_single_sign_on_records_on_external_id (external_id) UNIQUE
|
2019-01-30 09:33:53 +08:00
|
|
|
# index_single_sign_on_records_on_user_id (user_id)
|
2014-03-20 15:35:51 +11:00
|
|
|
#
|