Minor - Cleaning comments

skala
Julio Montoya 13 years ago
parent ef99cc756e
commit 5ef8dccd7d
  1. 4
      main/inc/lib/course.lib.php
  2. 11
      main/inc/lib/userportal.lib.php

@ -2918,8 +2918,7 @@ class CourseManager {
}
/**
* Display courses (without special courses) as several HTML divs
* of course categories, as class userportal-catalog-item.
* Display courses (without special courses) as several HTML divs of course categories
* @uses display_courses_in_category() to display the courses themselves
* @param int user id
* @param bool Whether to show the document quick-loader or not
@ -2986,6 +2985,7 @@ class CourseManager {
}
// Use user's classification for courses (if any).
$sql_select_courses .= " ORDER BY course_rel_user.user_course_cat, course_rel_user.sort ASC";
$result = Database::query($sql_select_courses);
$key = 0;
$status_icon = '';

@ -923,13 +923,14 @@ class IndexManager {
}
if (!empty($courses_tree)) {
foreach ($courses_tree as $cat => $sessions) {
$courses_tree[$cat]['details'] = SessionManager::get_session_category($cat);
//Get courses
if ($cat == 0) {
foreach ($courses_tree as $cat => $sessions) {
//Getting session categories
$courses_tree[$cat]['details'] = SessionManager::get_session_category($cat);
if ($cat == 0) {
$courses_tree[$cat]['courses'] = CourseManager::get_courses_list_by_user_id($user_id, false);
}
$courses_tree[$cat]['sessions'] = array_flip(array_flip($sessions));
//Get courses in sessions
if (count($courses_tree[$cat]['sessions']) > 0) {
foreach ($courses_tree[$cat]['sessions'] as $k => $s_id) {
@ -955,7 +956,7 @@ class IndexManager {
// Sessions and courses that are not in a session category.
// If we're not in the history view...
if (!isset($_GET['history'])) { //
if (!isset($_GET['history'])) {
//Display special courses
$html .= CourseManager :: display_special_courses($user_id, $this->load_directories_preview);
//Display courses

Loading…
Cancel
Save