-
Improvement
-
Resolution: Fixed
-
Major
-
2.3
-
MOODLE_23_STABLE
-
MOODLE_24_STABLE
-
MDL-31973-master-6 -
The role_assignments table has a 'component' field which is used to record which internal component created the assignment (it is blank if the assignment was added manually using the UI).
Unfortunately there is no 'component' field in the groups_members table.
We have a dataload system which automatically sets up tutor groups (and several other types of group) and it would make life significantly easier for this system if we could set a 'component' field in groups_members so that it can tell which rows it created. (I.e. there are cases where it needs to delete entries, but only if the system created them, otherwise it wipes manual changes.)
My proposal is to add the 'component' field to groups_members (with same semantics as in role_assignments, blank = manually added/normal).
I am not sure there is anywhere in Moodle that automatically creates group_members entries, but I'll search; if there is, I can make this fill in the component field. Otherwise, this feature would be solely for the use of plugins, so apart from the database change and maybe some changes to one or two groups_* functions (to add the new field, where there are lists of fields) it shouldn't change much.
Note: I am proposing to implement this myself.
- blocks
-
MDL-31437 consistent sync between cohorts and groups
- Closed
- caused a regression
-
MDL-35210 Delete testing code pushed upstream without noticing
- Closed
- duplicates
-
MDL-20863 Include "enrol" field to groups_members table to identify enrol plugins that created the record
- Closed
- has been marked as being related by
-
MDL-32005 groups and groupings should have 'idnumber' field
- Closed
-
MDL-51202 Groups table should have 'component' and 'itemid' fields
- Reopened
-
MDL-39170 Group Members should be greyed out if they aren't able to be removed.
- Closed