From 6849d15df51c3301aa75f941b36742d9035acc76 Mon Sep 17 00:00:00 2001 From: Frederic Massart Date: Wed, 1 Oct 2014 11:23:46 +0800 Subject: [PATCH] MDL-37707 mod_assign: Prevent user from changing grouping in team submissions --- mod/assign/mod_form.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mod/assign/mod_form.php b/mod/assign/mod_form.php index 77f556724e5..d60896b2ab8 100644 --- a/mod/assign/mod_form.php +++ b/mod/assign/mod_form.php @@ -155,6 +155,9 @@ class mod_assign_mod_form extends moodleform_mod { $mform->addElement('select', 'teamsubmissiongroupingid', $name, $options); $mform->addHelpButton('teamsubmissiongroupingid', 'teamsubmissiongroupingid', 'assign'); $mform->disabledIf('teamsubmissiongroupingid', 'teamsubmission', 'eq', 0); + if ($assignment->has_submissions_or_grades()) { + $mform->freeze('teamsubmissiongroupingid'); + } $mform->addElement('header', 'notifications', get_string('notifications', 'assign')); -- 2.11.4.GIT