Skip to content

Commit

Permalink
Gradebook: Fix missing skill tag for gradebook evaluations in gradebo…
Browse files Browse the repository at this point in the history
…ok index for students - refs BT#13334
  • Loading branch information
ywarnier committed Aug 23, 2022
1 parent 3cbfe3c commit 4b5b01e
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions main/gradebook/lib/fe/gradebooktable.class.php
Expand Up @@ -1245,6 +1245,7 @@ private function build_name_link($item, $type = 'detail', $spaces = 0)
// Evaluation
$course_id = CourseManager::get_course_by_category($categoryId);
$show_message = $cat->show_message_resource_delete($course_id);
$skills = $item->getSkillsFromItem();

// course/platform admin can go to the view_results page
if (api_is_allowed_to_edit() && $show_message === false) {
Expand All @@ -1258,7 +1259,7 @@ private function build_name_link($item, $type = 'detail', $spaces = 0)
if ('simple' === $type) {
$extra = '';
}
$extra .= $item->getSkillsFromItem();
$extra .= $skills;

return ' '
.'<a href="gradebook_view_result.php?'.api_get_cidreq().'&selecteval='.$item->get_id().'">'
Expand All @@ -1270,14 +1271,14 @@ private function build_name_link($item, $type = 'detail', $spaces = 0)
return '&nbsp;'
.'<a href="gradebook_statistics.php?'.api_get_cidreq().'&selecteval='.$item->get_id().'">'
.$item->get_name()
.'</a>';
.'</a>'.$skills;
} elseif ($show_message === false && !api_is_allowed_to_edit() && !ScoreDisplay::instance()->is_custom()) {
return '&nbsp;'
.'<a href="gradebook_statistics.php?'.api_get_cidreq().'&selecteval='.$item->get_id().'">'
.$item->get_name()
.'</a>';
.'</a>'.$skills;
} else {
return '['.get_lang('Evaluation').']&nbsp;&nbsp;'.$item->get_name().$show_message;
return '['.get_lang('Evaluation').']&nbsp;&nbsp;'.$item->get_name().$show_message.$skills;
}
// no break because of return
case 'L':
Expand Down

0 comments on commit 4b5b01e

Please sign in to comment.