Sha256: fb771689c254dbb38a1614c6112c05a6727ee8fb1f571bafc8c0f66a90b9dd5b
Contents?: true
Size: 933 Bytes
Versions: 5
Compression:
Stored size: 933 Bytes
Contents
<%= autogenerated_model_warning %> class Enrollment < ApplicationRecord include CanvasSync::ApiSyncable validates :canvas_enrollment_id, uniqueness: true, presence: true belongs_to :user, primary_key: :canvas_user_id, foreign_key: :canvas_user_id, optional: true belongs_to :course, primary_key: :canvas_course_id, foreign_key: :canvas_course_id, optional: true belongs_to :section, primary_key: :canvas_section_id, foreign_key: :canvas_section_id, optional: true api_syncable({ canvas_enrollment_id: :canvas_enrollment_id, canvas_course_id: :canvas_course_id, course_sis_id: :course_sis_id, canvas_user_id: :canvas_user_id, user_sis_id: :user_sis_id, canvas_section_id: :canvas_section_id, section_sis_id: :section_sis_id, role: :role, role_id: :role_id, status: :status, base_role_type: :base_role_type, }, -> (api) { api.enrollment("self", canvas_enrollment_id) }) end
Version data entries
5 entries across 5 versions & 1 rubygems