Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-60148

Quiz Grades report has inconsistent students logic

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Minor Minor
    • None
    • 3.2.5, 3.3.2
    • Quiz
    • MOODLE_32_STABLE, MOODLE_33_STABLE

      The Quiz Grades report has inconsistent students logic depending on if you are filtering by a group or not. If you are reporting without a group you get all students ever enrolled but if you filter on a group you get only currently enrolled students.

      From mod/quiz/report/attemptsreport.php in get_students_joins are these lines.

      $studentsjoins = get_enrolled_with_capabilities_join($this->context);

      // We have a currently selected group.
      $groupstudentsjoins = get_enrolled_with_capabilities_join($this->context, '',
      array('mod/quiz:attempt', 'mod/quiz:reviewmyattempts'), $currentgroup);

      This change came from MDL-27072. Before that both cases used the capabilities so you only reported on currently enrolled students. I did not see in the discussion of MDL-27072 where this was done intentionally.

      I think this is a bug and both cases should use the same logic for selecting students. I would favor adding the capabilities back to the first case as that returns the logic from before MDL-27072. Once I know which should be correct I can supply a patch.

      Note for this problem to show you need an uneroll action of Disable and remove roles rather than Unenroll from course.

            timhunt Tim Hunt
            jsw Jeff Webster
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.