|
|
@ -1802,8 +1802,8 @@ class Category implements GradebookItem |
|
|
|
if (isset($cats_course) && !empty($cats_course)) { |
|
|
|
if (isset($cats_course) && !empty($cats_course)) { |
|
|
|
$categories = Category::load(null, null, null, $category_id); |
|
|
|
$categories = Category::load(null, null, null, $category_id); |
|
|
|
if (!empty($categories)) { |
|
|
|
if (!empty($categories)) { |
|
|
|
foreach ($categories as $category) { |
|
|
|
foreach ($categories as $subCategory) { |
|
|
|
$sum_categories_weight_array[$category->get_id()] = $category->get_weight(); |
|
|
|
$sum_categories_weight_array[$subCategory->get_id()] = $subCategory->get_weight(); |
|
|
|
} |
|
|
|
} |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
$sum_categories_weight_array[$category_id] = $cats_course[0]->get_weight(); |
|
|
|
$sum_categories_weight_array[$category_id] = $cats_course[0]->get_weight(); |
|
|
|