Sha256: b5b2afe3846ee5e27a1d5cd49fc96f75fe3edcde10a101d61ee45a8ecc737afa
Contents?: true
Size: 952 Bytes
Versions: 7
Compression:
Stored size: 952 Bytes
Contents
# # # AUTO GENERATED MODEL # This model was auto generated by the CanvasSync Gem. # You can customize it as needed, but make sure you test # any changes you make to the auto generated methods. # class User < ApplicationRecord include CanvasSync::Record include CanvasSync::Concerns::ApiSyncable validates :canvas_id, uniqueness: true, presence: true has_many :enrollments, primary_key: :canvas_id, foreign_key: :canvas_user_id has_many :admins, primary_key: :canvas_id, foreign_key: :canvas_user_id has_many :admin_roles, through: :admins, source: :role has_many :submissions, primary_key: :canvas_id, foreign_key: :canvas_user_id has_many :group_memberships, primary_key: :canvas_id, foreign_key: :canvas_user_id api_syncable({ sis_id: :sis_user_id, email: :email, login_id: :login_id, name: :name, sortable_name: :sortable_name, first_name: :short_name, }, -> (api) { api.user_detail(canvas_id) }) end
Version data entries
7 entries across 7 versions & 1 rubygems