chamilo/chamilo-lms

View on GitHub
public/main/my_space/current_courses.php

Summary

Maintainability
A
0 mins
Test Coverage

Variable "teacher_list" is not in valid camel caps format
Open

        $teacher_list = [];

Variable "tmp_students" is not in valid camel caps format
Open

        foreach ($tmp_students as $student) {

Variable "teacher_list" is not in valid camel caps format
Open

                    $array[$i]['teachers'] = implode(', ', $teacher_list);

Variable "avg_progress_in_course" is not in valid camel caps format
Open

                        if (intval($avg_progress_in_course) > 0 && intval($avg_progress_in_course) <= 50) {

Variable "time_spent" is not in valid camel caps format
Open

                        $time_spent = Tracking::get_time_spent_on_the_course($student_id, $course_id, $session_id);

Variable "total_time_spent" is not in valid camel caps format
Open

                        $total_time_spent += $time_spent;

Variable "student_count" is not in valid camel caps format
Open

                $student_count = count($students);

Variable "my_courses" is not in valid camel caps format
Open

$my_courses = CourseManager::get_course_list_of_user_as_course_admin($user_id);

Variable "course_code" is not in valid camel caps format
Open

        $tmp_students = CourseManager::get_student_list_from_course_code($course_code, false);

Variable "count_students_accessing" is not in valid camel caps format
Open

                $count_students_accessing = 0;

Variable "avg_student_progress" is not in valid camel caps format
Open

                        $avg_student_progress = Tracking::get_avg_student_progress($student_id, $course_code, [$lp_id], $session_id);

Variable "session_id" is not in valid camel caps format
Open

                        $time_spent = Tracking::get_time_spent_on_the_course($student_id, $course_id, $session_id);

Variable "course_info" is not in valid camel caps format
Open

        $course_info = api_get_course_info_by_id($course['id']);

Variable "session_id" is not in valid camel caps format
Open

            $session_id

Variable "total_tools_list" is not in valid camel caps format
Open

        foreach ($total_tools_list as $tool) {

Variable "student_id" is not in valid camel caps format
Open

                        $avg_student_progress = Tracking::get_avg_student_progress($student_id, $course_code, [$lp_id], $session_id);

Variable "avg_progress_in_course" is not in valid camel caps format
Open

                        $avg_progress_in_course = Tracking::get_avg_student_progress($student_id, $course_code, [$lp_id], $session_id);

Variable "lp_id" is not in valid camel caps format
Open

                $array[$i]['lp'] = '<a href="'.api_get_path(WEB_CODE_PATH).'lp/lp_controller.php?cidReq='.$course_code.'&amp;action=view&amp;lp_id='.$lp_id.'" target="_blank">'.$learnpath['title'].'</a>';

Variable "count_students_complete_all_activities" is not in valid camel caps format
Open

                $count_students_complete_all_activities = 0;

Variable "course_code" is not in valid camel caps format
Open

                        $myavg_temp = Tracking::get_avg_student_score($student_id, $course_code, [$lp_id], $session_id);

Variable "session_id" is not in valid camel caps format
Open

                        $avg_progress_in_course = Tracking::get_avg_student_progress($student_id, $course_code, [$lp_id], $session_id);

Variable "total_average_progress" is not in valid camel caps format
Open

                        $total_average_progress += $avg_progress_in_course;

Variable "my_courses" is not in valid camel caps format
Open

if (!empty($my_courses)) {

Variable "course_code" is not in valid camel caps format
Open

        $course_code = $course_info['code'];

Variable "teacher_list" is not in valid camel caps format
Open

                $teacher_list[] = $teacher['firstname'].' '.$teacher['lastname'];

Variable "t_news" is not in valid camel caps format
Open

        $t_news = Database::get_course_table(TABLE_ANNOUNCEMENT);

Variable "avg_progress_in_course" is not in valid camel caps format
Open

                        $total_average_progress += $avg_progress_in_course;

Variable "sql_lpi" is not in valid camel caps format
Open

                $sql_lpi = "SELECT lpi.item_type FROM $t_lpi lpi

Variable "t_lpi" is not in valid camel caps format
Open

                $sql_lpi = "SELECT lpi.item_type FROM $t_lpi lpi

Variable "course_info" is not in valid camel caps format
Open

        $course_code = $course_info['code'];

Variable "course_code" is not in valid camel caps format
Open

        $teachers = CourseManager::get_teacher_list_from_course_code($course_code);

Variable "t_lp" is not in valid camel caps format
Open

        $t_lp = Database::get_course_table(TABLE_LP_MAIN);

Variable "course_id" is not in valid camel caps format
Open

                   WHERE li.c_id = $course_id AND li.session_id = 0";

Variable "t_lpi" is not in valid camel caps format
Open

        $t_lpi = Database::get_course_table(TABLE_LP_ITEM);

Variable "student_id" is not in valid camel caps format
Open

                        $avg_progress_in_course = Tracking::get_avg_student_progress($student_id, $course_code, [$lp_id], $session_id);

Variable "count_students_complete_all_activities" is not in valid camel caps format
Open

                            $count_students_complete_all_activities++;

Variable "user_info" is not in valid camel caps format
Open

            if (STUDENT != $user_info['status']) {

Variable "student_id" is not in valid camel caps format
Open

                    foreach ($students  as $student_id) {

Variable "time_spent" is not in valid camel caps format
Open

                        if (!empty($time_spent)) {

Variable "session_id" is not in valid camel caps format
Open

$session_id = 0;

Variable "course_id" is not in valid camel caps format
Open

            $course_id,

Variable "count_students_complete_all_activities_at_50" is not in valid camel caps format
Open

                $count_students_complete_all_activities_at_50 = 0;

Variable "course_id" is not in valid camel caps format
Open

                        $time_spent = Tracking::get_time_spent_on_the_course($student_id, $course_id, $session_id);

Variable "time_spent" is not in valid camel caps format
Open

                        $total_time_spent += $time_spent;

Variable "student_count" is not in valid camel caps format
Open

                $array[$i]['count_students'] = $student_count;

Variable "my_courses" is not in valid camel caps format
Open

    foreach ($my_courses as $course) {

Variable "tmp_students" is not in valid camel caps format
Open

        $tmp_students = CourseManager::get_student_list_from_course_code($course_code, false);

Variable "sql_lp" is not in valid camel caps format
Open

        $sql_lp = "SELECT lp.title, lp.iid FROM $t_lp lp

Variable "course_code" is not in valid camel caps format
Open

                        $avg_student_progress = Tracking::get_avg_student_progress($student_id, $course_code, [$lp_id], $session_id);

Variable "student_id" is not in valid camel caps format
Open

                        $myavg_temp = Tracking::get_avg_student_score($student_id, $course_code, [$lp_id], $session_id);

Variable "course_code" is not in valid camel caps format
Open

                        $avg_progress_in_course = Tracking::get_avg_student_progress($student_id, $course_code, [$lp_id], $session_id);

Variable "this_section" is not in valid camel caps format
Open

$this_section = SECTION_TRACKING;

Variable "t_lp" is not in valid camel caps format
Open

        $sql_lp = "SELECT lp.title, lp.iid FROM $t_lp lp

Variable "avg_progress_in_course" is not in valid camel caps format
Open

                        if (intval($avg_progress_in_course) > 0 && intval($avg_progress_in_course) <= 50) {

Variable "user_id" is not in valid camel caps format
Open

$user_id = api_get_user_id();

Variable "user_info" is not in valid camel caps format
Open

            $user_info = api_get_user_info($student['user_id']);

Variable "rs_lp" is not in valid camel caps format
Open

        $rs_lp = Database::query($sql_lp);

Variable "session_id" is not in valid camel caps format
Open

                        $avg_student_progress = Tracking::get_avg_student_progress($student_id, $course_code, [$lp_id], $session_id);

Variable "count_students_complete_all_activities_at_50" is not in valid camel caps format
Open

                            $count_students_complete_all_activities_at_50++;

Variable "lp_id" is not in valid camel caps format
Open

                $lp_id = $learnpath['iid'];

Variable "total_time_spent" is not in valid camel caps format
Open

                $total_time_spent = 0;

Variable "session_id" is not in valid camel caps format
Open

                        $myavg_temp = Tracking::get_avg_student_score($student_id, $course_code, [$lp_id], $session_id);

Variable "avg_progress_in_course" is not in valid camel caps format
Open

                        if (100 == intval($avg_progress_in_course)) {

Variable "course_info" is not in valid camel caps format
Open

        if (0 == $course_info['visibility']) {

Variable "lp_items" is not in valid camel caps format
Open

                $lp_items =

Variable "total_average_progress" is not in valid camel caps format
Open

                $total_average_progress = 0;

Expected 1 space before "as"; 2 found
Open

                    foreach ($students  as $student_id) {

Variable "user_id" is not in valid camel caps format
Open

$my_courses = CourseManager::get_course_list_of_user_as_course_admin($user_id);

Variable "sql_lp" is not in valid camel caps format
Open

        $rs_lp = Database::query($sql_lp);

Variable "total_tools_list" is not in valid camel caps format
Open

        $total_tools_list = Tracking::get_tools_most_used_by_course(

Variable "total_tools" is not in valid camel caps format
Open

        $total_tools = 0;

Variable "total_tools" is not in valid camel caps format
Open

            $total_tools += $tool['count_access_tool'];

Variable "rs_lp" is not in valid camel caps format
Open

            while ($learnpath = Database :: fetch_array($rs_lp)) {

Variable "myavg_temp" is not in valid camel caps format
Open

                        $myavg_temp = Tracking::get_avg_student_score($student_id, $course_code, [$lp_id], $session_id);

Variable "course_code" is not in valid camel caps format
Open

                $array[$i]['lp'] = '<a href="'.api_get_path(WEB_CODE_PATH).'lp/lp_controller.php?cidReq='.$course_code.'&amp;action=view&amp;lp_id='.$lp_id.'" target="_blank">'.$learnpath['title'].'</a>';

Variable "lp_id" is not in valid camel caps format
Open

                        $avg_progress_in_course = Tracking::get_avg_student_progress($student_id, $course_code, [$lp_id], $session_id);

Variable "teacher_list" is not in valid camel caps format
Open

                if (!empty($teacher_list)) {

Variable "count_students_accessing" is not in valid camel caps format
Open

                            $count_students_accessing++;

Variable "course_id" is not in valid camel caps format
Open

                            WHERE c_id = $course_id AND lpi.lp_id = $lp_id

Variable "lp_id" is not in valid camel caps format
Open

                        $avg_student_progress = Tracking::get_avg_student_progress($student_id, $course_code, [$lp_id], $session_id);

Variable "lp_id" is not in valid camel caps format
Open

                        $myavg_temp = Tracking::get_avg_student_score($student_id, $course_code, [$lp_id], $session_id);

Variable "student_id" is not in valid camel caps format
Open

                        $time_spent = Tracking::get_time_spent_on_the_course($student_id, $course_id, $session_id);

Variable "course_id" is not in valid camel caps format
Open

        $course_id = $course['id'];

Variable "rs_lp" is not in valid camel caps format
Open

        if (Database :: num_rows($rs_lp) > 0) {

Variable "count_students_complete_all_activities_at_50" is not in valid camel caps format
Open

                $count_students_complete_all_activities_at_50 = 0;

Variable "sql_lpi" is not in valid camel caps format
Open

                $res_lpi = Database::query($sql_lpi);

Variable "row_lpi" is not in valid camel caps format
Open

                while ($row_lpi = Database::fetch_array($res_lpi)) {

Variable "res_lpi" is not in valid camel caps format
Open

                while ($row_lpi = Database::fetch_array($res_lpi)) {

Variable "student_count" is not in valid camel caps format
Open

                    $array[$i]['count_students_accessing_percentage'] = round($count_students_accessing / $student_count * 100, 0);

Variable "lp_id" is not in valid camel caps format
Open

                            WHERE c_id = $course_id AND lpi.lp_id = $lp_id

Variable "res_lpi" is not in valid camel caps format
Open

                $res_lpi = Database::query($sql_lpi);

Variable "sql_news" is not in valid camel caps format
Open

                $res_news = Database::query($sql_news);

Variable "student_count" is not in valid camel caps format
Open

                    $array[$i]['count_students_complete_all_activities'] = round($count_students_complete_all_activities / $student_count * 100, 0);

Variable "count_students_complete_all_activities" is not in valid camel caps format
Open

                    $array[$i]['average_percentage_activities_completed_per_student'] = round($count_students_complete_all_activities / $student_count * 100, 2);

Variable "row_news" is not in valid camel caps format
Open

                    $array[$i]['total_announcements'] = $row_news[0];

Variable "row_lpi" is not in valid camel caps format
Open

                    switch ($row_lpi['item_type']) {

Variable "res_news" is not in valid camel caps format
Open

                $res_news = Database::query($sql_news);

Variable "count_students_accessing" is not in valid camel caps format
Open

                    $array[$i]['count_students_accessing_percentage'] = round($count_students_accessing / $student_count * 100, 0);

Variable "student_count" is not in valid camel caps format
Open

                        $array[$i]['average_time_spent_per_student'] = api_time_to_hms($total_time_spent / $student_count);

Variable "sql_news" is not in valid camel caps format
Open

                $sql_news = "SELECT count(id) FROM $t_news WHERE c_id = $course_id ";

Variable "student_count" is not in valid camel caps format
Open

                    $array[$i]['average_percentage_activities_completed_per_student'] = round($count_students_complete_all_activities / $student_count * 100, 2);

Variable "row_news" is not in valid camel caps format
Open

                while ($row_news = Database::fetch_array($res_news)) {

Variable "res_news" is not in valid camel caps format
Open

                while ($row_news = Database::fetch_array($res_news)) {

Variable "student_count" is not in valid camel caps format
Open

                if (!empty($student_count)) {

Variable "count_students_complete_all_activities" is not in valid camel caps format
Open

                    $array[$i]['count_students_complete_all_activities'] = round($count_students_complete_all_activities / $student_count * 100, 0);

Variable "t_news" is not in valid camel caps format
Open

                $sql_news = "SELECT count(id) FROM $t_news WHERE c_id = $course_id ";

Variable "count_students_accessing" is not in valid camel caps format
Open

                    $array[$i]['count_students_accessing'] = $count_students_accessing;

Variable "total_time_spent" is not in valid camel caps format
Open

                    if (!empty($total_time_spent)) {

Variable "course_id" is not in valid camel caps format
Open

                $sql_news = "SELECT count(id) FROM $t_news WHERE c_id = $course_id ";

Variable "total_time_spent" is not in valid camel caps format
Open

                        $array[$i]['total_time_spent'] = api_time_to_hms($total_time_spent);

Variable "row_table" is not in valid camel caps format
Open

    foreach ($row_table as $cell) {

Variable "count_students_complete_all_activities" is not in valid camel caps format
Open

                    $array[$i]['count_students_complete_all_activities_at_50'] = $count_students_complete_all_activities;

Variable "total_time_spent" is not in valid camel caps format
Open

                        $array[$i]['average_time_spent_per_student'] = api_time_to_hms($total_time_spent / $student_count);

Variable "row_table" is not in valid camel caps format
Open

foreach ($array as $row_table) {

There are no issues that match your filters.

Category
Status