added AuthenticationToken model, updated some restrictions for the authentication token table, added dependent destroy to the user model for authentication tokens
This commit is contained in:

committed by
Sebastian Serth

parent
fe410a5306
commit
d64daadd21
@ -6,6 +6,7 @@ class User < ApplicationRecord
|
||||
ROLES = %w[admin teacher learner].freeze
|
||||
|
||||
belongs_to :consumer
|
||||
has_many :authentication_token, dependent: :destroy
|
||||
has_many :study_group_memberships, as: :user
|
||||
has_many :study_groups, through: :study_group_memberships, as: :user
|
||||
has_many :exercises, as: :user
|
||||
|
Reference in New Issue
Block a user