headless_lms_models::course_modules

Function get_by_course_id_as_map

Source
pub async fn get_by_course_id_as_map(
    conn: &mut PgConnection,
    course_id: Uuid,
) -> ModelResult<HashMap<Uuid, CourseModule>>
Expand description

Gets course modules for the given course as a map, indexed by the id field.