Uploaded image for project: 'Plugins'
  1. Plugins
  2. CONTRIB-5736

Questionnaire downloading responses doesn't take course group mode into account

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.6.10, 2.7.8, 2.8.6
    • Fix Version/s: 2.7.10, 2.8.8, 2.9
    • Component/s: Module: Questionnaire
    • Labels:
      None
    • Affected Branches:
      MOODLE_26_STABLE, MOODLE_27_STABLE, MOODLE_28_STABLE
    • Fixed Branches:
      MOODLE_27_STABLE, MOODLE_28_STABLE, MOODLE_29_STABLE

      Description

      When downloading response data for questionnaires, the course groupmode is not taken into account when determining which group(s) a respondent is a member of.

      Following patch fixes this issue (for the Moodle 2.6 plugin version; although the 2.7 & 2.8 branches also have the same problem).

      diff --git a/questionnaire.class.php b/questionnaire.class.php
      index 53a2546..1962a46 100644
      — a/questionnaire.class.php
      +++ b/questionnaire.class.php
      @@ -2788,7 +2788,7 @@ class questionnaire {
      // Moodle:
      // Determine if the user is a member of a group in this course or not.
      $groupname = '';

      • if ($this->cm->groupmode > 0) {
        + if (groups_get_activity_groupmode($this->cm, $this->course)) {
        if ($currentgroupid > 0)
        Unknown macro: { $groupname = groups_get_group_name($currentgroupid); }

        else {

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                1 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  11/May/15