Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-11573 META: New gradebook bugs reported by OU
  3. MDL-11580

Quiz grade reports need to be hidden from tutors while the quiz is open

    XMLWordPrintable

    Details

    • Type: Sub-task
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.9
    • Fix Version/s: 1.9
    • Component/s: Gradebook, Quiz
    • Labels:
      None
    • Affected Branches:
      MOODLE_19_STABLE
    • Fixed Branches:
      MOODLE_19_STABLE

      Description

      After some thought, we need to hack the quiz with an open-university-specific hack. We can control this using a $CFG->openuniversityhacks = true in config.php

      The idea is to disallow "tutors" from seeing all the grades (reports) in a quiz until the quiz has finished.

      So, we basically need to add a bit of logic like this:

      $canviewhidden = has_capability('moodle/grade:viewhidden', get_context_instance(CONTEXT_COURSE, $this->course->id));

      if (isset($CFG->openuniversityhacks) && !$canviewhidden && $quiz->timeclose && $quiz->timeclose > time() ) {
      // FORCE THE QUIZ TO APPEAR AS FOR A STUDENT (NO EDIT, NO GRADE VIEW, NO REPORTS etc)
      }

        Attachments

          Activity

            People

            • Assignee:
              skodak Petr Skoda
              Reporter:
              dougiamas Martin Dougiamas
              Tester:
              Nobody
              Participants:
              Component watchers:
              Jake Dallimore, Jun Pataleta, Ryan Wyllie, Tim Hunt, Andrew Nicols, Mathew May, Michael Hawkins, Shamim Rezaie, Simey Lameze
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Fix Release Date:
                3/Mar/08