| @@ 880-901 (lines=22) @@ | ||
| 877 | * including users from linked courses |
|
| 878 | * @deprecate use CourseManager class |
|
| 879 | */ |
|
| 880 | public static function get_course_users() |
|
| 881 | { |
|
| 882 | //this would return only the users from real courses: |
|
| 883 | $session_id = api_get_session_id(); |
|
| 884 | if ($session_id != 0) { |
|
| 885 | $userList = CourseManager::get_real_and_linked_user_list( |
|
| 886 | api_get_course_id(), |
|
| 887 | true, |
|
| 888 | $session_id, |
|
| 889 | true |
|
| 890 | ); |
|
| 891 | } else { |
|
| 892 | $userList = CourseManager::get_real_and_linked_user_list( |
|
| 893 | api_get_course_id(), |
|
| 894 | false, |
|
| 895 | 0, |
|
| 896 | true |
|
| 897 | ); |
|
| 898 | } |
|
| 899 | ||
| 900 | return $userList; |
|
| 901 | } |
|
| 902 | ||
| 903 | /** |
|
| 904 | * this function gets all the groups of the course, |
|
| @@ 5703-5714 (lines=12) @@ | ||
| 5700 | * this function gets all the users of the course, |
|
| 5701 | * including users from linked courses |
|
| 5702 | */ |
|
| 5703 | public static function getCourseUsers() |
|
| 5704 | { |
|
| 5705 | //this would return only the users from real courses: |
|
| 5706 | $session_id = api_get_session_id(); |
|
| 5707 | if ($session_id != 0) { |
|
| 5708 | $user_list = self::get_real_and_linked_user_list(api_get_course_id(), true, $session_id); |
|
| 5709 | } else { |
|
| 5710 | $user_list = self::get_real_and_linked_user_list(api_get_course_id(), false, 0); |
|
| 5711 | } |
|
| 5712 | ||
| 5713 | return $user_list; |
|
| 5714 | } |
|
| 5715 | ||
| 5716 | /** |
|
| 5717 | * this function gets all the groups of the course, |
|