diff --git a/Types/Course.cs b/Types/Course.cs index ad147b6..fc9394b 100644 --- a/Types/Course.cs +++ b/Types/Course.cs @@ -64,7 +64,7 @@ public class Course : CanvasObject [JsonProperty("start_at")] public DateTime? StartDate { get; set; } [JsonProperty("end_at")] - public DateTime? EndDate{ get; set; } + public DateTime? EndDate { get; set; } [JsonProperty("course_code")] public string CourseCode { get; set; } [JsonProperty("sis_course_id")] @@ -76,6 +76,9 @@ public class Course : CanvasObject [JsonProperty("workflow_state")] public CourseState State { get; set; } + [JsonProperty("course_image")] + public string Image { get; set; } + [JsonProperty("grading_standard_enabled")] public bool? EnableGradingScheme { get; set; } [JsonProperty("grading_standard_id")] @@ -144,7 +147,7 @@ public class Course : CanvasObject public List UserEnrollments => _UserEnrollments ?? (_UserEnrollments = Connector.RetrieveCollection(this, param: ("user_id", "self"))); public List GetEnrollmentsByType(EnrollmentType type) => Connector.RetrieveCollection(this, null, ("type", ToCanvasString(type))); - public List GetEnrollmentsByType(EnrollmentType type, string[] sisuserIds) + public List GetEnrollmentsByType(EnrollmentType type, string[] sisuserIds) => Connector.RetrieveCollection(this, sisuserIds.Select(i => ("sis_user_id[]", i)).Append(("type", ToCanvasString(type))).ToArray()); public List GetUsersByType(EnrollmentType type) => Connector.RetrieveCollection(this, null, ("enrollment_type", type.ToString().ToLower()));