gradebook 1.5 loses advanced settings

gradebook 1.5 loses advanced settings

by Jeff Graham -
Number of replies: 3
Hi all,

I don't have time to implement this fix to the gradebook as I am working on other projects that currently have higher priority.

There is a bug with the new gradebook when a user turns advanced features off they lose all of their gradebook settings. Preferably the gradebook should do one of the following:
  • quick fix: let the user know they will lose all of their settings use a javascript confirm or similar to make sure this is what they want to do.
  • ideal solution: conditionally use the advanced features based on how the users gradebook is set. This basically amounts to wrapping grade calculating blocks within the function "grade_get_formatted_grades()" and only conditionally executing the "advanced" sections if the gradebook is set to "use advanced features" unfortunately this is the majority of the new gradebook code and the data structure created is a little bulky due to the combination of advanced features and non-centralized grades.
Any other comments/solutions would be great.

regards,
Jeff
In reply to Jeff Graham

Re: gradebook 1.5 loses advanced settings

by dan sherman -
What about the solution of: Saving the "Advanced Grade" settings, and storing them, but flipping a flag to use/not use them.  So if someone turns them off, and turns them back on, the settings will still be there, just whether they are used or not is changed...
In reply to dan sherman

Re: gradebook 1.5 loses advanced settings

by Jeff Graham -
Dan,

What you suggest is essentially what the plan is for the more "ideal solution", we wouldn't even need to bother with the settings really. We would just need to change the behavior of the get_preferences function to return "basic" settings regardless of their actual setting if use_advanced is false. Then we would need to modify the get_grades function(s) as mentioned above.
In reply to Jeff Graham

Re: gradebook 1.5 loses advanced settings

by dan sherman -
Yup, unfortunately I posted before looking into the code =P

I see what you mean =P