File tree Expand file tree Collapse file tree 2 files changed +15
-4
lines changed
Expand file tree Collapse file tree 2 files changed +15
-4
lines changed Original file line number Diff line number Diff line change @@ -7855,10 +7855,18 @@ public static function getExpirationDateByRole($status)
78557855
78567856 public static function getAllowedRolesAsTeacher (): array
78577857 {
7858- return [
7859- COURSEMANAGER ,
7860- SESSIONADMIN ,
7861- ];
7858+ if (api_get_configuration_value ('course_allow_student_role_to_be_teacher ' )) {
7859+ return [
7860+ STUDENT ,
7861+ COURSEMANAGER ,
7862+ SESSIONADMIN ,
7863+ ];
7864+ } else {
7865+ return [
7866+ COURSEMANAGER ,
7867+ SESSIONADMIN ,
7868+ ];
7869+ }
78627870 }
78637871
78647872 /**
Original file line number Diff line number Diff line change 25302530
25312531// Add the user first connexion column to the page main/admin/user_list.php
25322532// $_configuration['admin_user_list_add_first_connexion_column'] = false;
2533+
2534+ // Set the following parameter to true to enable student to be assign as teacher of a course
2535+ //$_configuration['course_allow_student_role_to_be_teacher'] = false;
You can’t perform that action at this time.
0 commit comments