Issue Details (XML | Word | Printable)

Key: MDL-10904
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Yu Zhang
Reporter: A. T. Wyatt
Votes: 8
Watchers: 7
Operations

Add/Edit UI Mockup to this issue
If you were logged in you would be able to see more operations.
Moodle

Exclude not working in gradebook 1.8.2

Created: 18/Aug/07 05:17 AM   Updated: 06/Feb/08 05:51 AM
Component/s: Gradebook
Affects Version/s: 1.8.2
Fix Version/s: 1.8.3

File Attachments: 1. HTML File exceptions.html (7 kB)

Environment: all--testing on WIMP and LAMP. Same behavior
Issue Links:
Duplicate
 

Participants: A. T. Wyatt, Anthony Borrow, Chris Ament, David DeLauro, Kenneth Newquist, Steve Hannah and Yu Zhang
Security Level: None
Resolved date: 25/Sep/07
Affected Branches: MOODLE_18_STABLE
Fixed Branches: MOODLE_18_STABLE


 Description  « Hide
This was filed in the contrib area as
http://tracker.moodle.org/browse/CONTRIB-71

However, upon further testing, this doesn't seem to be working in any of my moodle instances. Therefore, I believe the problem is in core.

When I go to the grade exceptions screen, I
select a student who is third in the list
select the third assignment in the list
click "exclude from grading" and the third student is excluded from the FIRST assignment in the list.

No matter which assignment I select, the exclusion is reported to the first assignment in the list.

 All   Comments   Change History   Version Control      Sort Order: Ascending order - Click to sort in descending order
A. T. Wyatt added a comment - 18/Aug/07 05:21 AM
moodle 2007021520

Steve Hannah added a comment - 24/Aug/07 03:05 AM - edited
We have been able to replicate this issue in several courses on 1.8.2. It appears that Exceptions can only be created for the first Grade Item, even if a different Grade Item is selected. In one course, we can create an exclusion for all students for the first Grade Item, in another course we can only create an exclusion for the first student for the first Grade Item.

David DeLauro added a comment - 30/Aug/07 05:27 AM
It appears to be an issue with the javascript or at least that might be a good place to start. I get an error of an undefined variable grade_item in the updateMembers function just loading the page. If I try to highlight an assignment I get an error of getElementById being undefined.

grade_item undefined is not defined
http://moodle.saintjoe.edu/moodle/grade/exceptions.php?id=176&action=excepts
eval('grade_item=grade_item'+selectgrade_item.value);
Line 149

getElementById is not defined
http://moodle.saintjoe.edu/moodle/grade/exceptions.php?id=176&action=excepts
getElementById('form3')['members[]'].length = username.length;
Line 154


Anthony Borrow added a comment - 30/Aug/07 07:04 AM
The discussion at: http://moodle.org/mod/forum/discuss.php?d=71428 may be helpful.

Chris Ament added a comment - 13/Sep/07 05:03 AM
getElementById is a method provided by the document object. The fix for this is trivial - add replace getElementById with document.getElementById. Attached file has this change applied and seems to work fine.

Yu Zhang added a comment - 14/Sep/07 11:34 AM
Thanks guys, changed all instances of getElementById to document.getElementById() as suggest. Please let me know if this can be closed. Thanks.

Kenneth Newquist added a comment - 22/Sep/07 03:33 AM
This fix worked for me; I think this can be closed and added to core.

Steve Hannah added a comment - 22/Sep/07 03:48 AM
We have not had any problems with Exclude from Grading since this fix. I believe it can be closed.

Yu Zhang added a comment - 25/Sep/07 10:26 AM
Thanks guys, closing.