Details
-
Bug
-
Resolution: Fixed
-
Minor
-
2.8.8, 2.9
-
MOODLE_28_STABLE, MOODLE_29_STABLE
-
MOODLE_28_STABLE, MOODLE_29_STABLE
-
Description
The quiz notification ignores the GROUPING settings.
For example we have got two tutors in the same course but they would like to share the grading task between themselves: tutor1 would like to mark Quiz1 and tutor2 would like to mark Quiz2 and we would like to send them notification to let them know when a student submitted something...
- Create a course
- Enrol two non editing teachers (tutor1 and tutor2)
- Enrol two students (student1 and student2)
- Create two groups for the two teachers (t1 and t2)
- t1 members: tutor1, student1 and student2
- t2 members: tutor2, student1 and student2
- Create two groupings( gr1 and gr2)
- gr1 contains t1
- gr2 contains t2
- Create a quiz: quiz1, group mode: SEPARATE GROUPS, grouping: GR1
- create a new ESSAY QUESTION
- go to quiz administration: permissions, allow NON EDITING TEACHER the "Get a notification message when an attempt is submitted" capability (mod/quiz:emailnotifysubmission)
- go to Site administration / ► Users / ► Permissions / ► Define roles
- choose non editing teacher, edit
- Access all groups (moodle/site:accessallgroups): not set
After these settings when a student submit a quiz attempt ONLY tutor1 should get a notification about the submission, but if you login as student1 and attempt the quiz, both tutor will get a notification.
The problem is in the
mod/quiz/locallib.php
file:
line 1553:
$groups = groups_get_all_groups($course->id, $submitter->id);
should be:
$groups = groups_get_all_groups($course->id, $submitter->id, $cm->groupingid);
see my solution here:
https://github.com/lengyelke/moodle/commit/2fa0eaaa3244a94b76974b94f737ea29b63814bf
I hope I was clear enough
Thanks
Frank
Attachments
Issue Links
- Testing discovered
-
MDL-51608 Warning debug messages being displayed when sending notification emails after attempting a quiz
-
- Closed
-