MDL-27459 Completion: When ratings off, disallow grade completion
authorsam marshall <s.marshall@open.ac.uk>
Tue, 8 Apr 2014 10:55:46 +0000 (11:55 +0100)
committersam marshall <s.marshall@open.ac.uk>
Tue, 29 Apr 2014 09:28:34 +0000 (10:28 +0100)
commit97c3c2c2cc4a49c56cc00447e3fac53a525beebf
tree6ecceab4a9960267a8ba096218be2331fbec1f2c
parent83ddacfff7cf45727f4ac6f6e983b5f8686b91b5
MDL-27459 Completion: When ratings off, disallow grade completion

For activities that use ratings, there is no grade unless ratings
are enabled. The completion system still lets you select 'complete
when user gets a grade', which leads to later errors.

This change simply disables the 'completion on grade' field if
ratings are enabled for the activity, but not turned on in the form.
course/moodleform_mod.php