mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 08:56:36 +02:00
MDL-22033 groupings now enabled unconditionally, groupmembersonly kept as experimental - this simplifies groups code logic a bit, user interface changes should not be significant because the groupings are not visible much until at least one created; hopefully the new description of groupmembersonly will have to preventsome gradebook complaints
This commit is contained in:
parent
e8c2189d78
commit
98da60215e
31 changed files with 137 additions and 214 deletions
|
@ -320,7 +320,7 @@ class external_api {
|
|||
throw new invalid_parameter_exception('Invalid activity.');
|
||||
}
|
||||
// verify group memebers
|
||||
if (!empty($CFG->enablegroupings) and $cm and $cm->groupmembersonly and !has_capability('moodle/site:accessallgroups', get_context_instance(CONTEXT_MODULE, $cm->id))) {
|
||||
if (!empty($CFG->enablegroupmembersonly) and $cm and $cm->groupmembersonly and !has_capability('moodle/site:accessallgroups', get_context_instance(CONTEXT_MODULE, $cm->id))) {
|
||||
if (!groups_has_membership($cm)) {
|
||||
throw new invalid_parameter_exception('Must be member of at least one group.');
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue