Issue Details (XML | Word | Printable)

Key: MDL-10383
Type: New Feature New Feature
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Petr Skoda
Reporter: Enrique Castro
Votes: 1
Watchers: 4
Operations

Add/Edit UI Mockup to this issue
If you were logged in you would be able to see more operations.
Moodle

Make modules to declare and use Groupings

Created: 09/Jul/07 06:58 AM   Updated: 03/Oct/07 11:52 PM
Return to search
Component/s: Groups
Affects Version/s: 1.9
Fix Version/s: 1.9

File Attachments: 1. File diff-ulpgc_groupings-08-07-07 (69 kB)
2. File groups-db-libchanges.diff (55 kB)
3. File groups.dia (2 kB)
4. Text File groups_cleanup2.patch (114 kB)
5. File patch-Bugz-2617-group_cm.diff (44 kB)
6. File patch-MDL-10383-groups-db-v6.diff (57 kB)
7. File patch-MDL-10383-groups-lib-clean-p1.diff (30 kB)

Issue Links:
Dependency
Duplicate

URL: http://moodle.ulpgc.es/moodle19ulpgc/course/view.php?id=3
Participants: Enrique Castro, Martin Dougiamas, Matt Clarkson, Nick Freear, Petr Skoda and Sam Marshall
Security Level: None
QA Assignee: Helen Foster
Resolved date: 03/Oct/07
Affected Branches: MOODLE_19_STABLE
Fixed Branches: MOODLE_19_STABLE

Sub-Tasks  All   Open   
 Sub-Task Progress: 
No sub-tasks match this view.

 Description  « Hide
Groupings were introduced in version 1.8 as a way to organize groups within a course. However, groupings do not have any practical use in version 1.8 or current 1.9 (HEAD). As in 1.8/1.9 Groupings are more a useless complication than a useful feature. To be productive Groupings must be USED by activity modules. I have proposed a whole new range of groups/groupings features combining the design goals (but not yet implemented) of OU and the implemented version of Groupings working at ULPGC. The spec proposal may be found at http://docs.moodle.org/en/Development:Groupings_and_Groups

At this stage I will concentrate in two new features:

a) Making possible to use different groupings by different activities.
Activities can declare a grouping to use. This means that when that particular activity is set as visible/separate groups, the particular groups used are those belonging to the declared grouping. Hence, we can have simultaneous activities where users are distributed according to different criteria, activities & resources may be targeted to different audiences.

The needed changes are adding a field "groupingid" to the courses and course_modules tables to hold the grouping that the course itself or each module instance will use when set in visible/separate groupmode. By "using grouping" I mean that grouping-aware functions should operate nor on all groups associated with a course but only those associated with a grouping. So, you may have a forum declaring a grouping and thus using a particular set of groups. At the same time other activity in the course, let say an assignment may declare other grouping and thus treat the same users as distributed in a completely different set of groups.

"Use grouping" must be added to the configuration form for each module instance, parallel to "groupmode" attribute. Best way is to add to te common module settings

Module code must be adapted to ensure that $cm->groupingid property now existing is passed to groups-API functions within the module code to return/manage only those groups belonging to the declared grouping.


b) Group-based content delivery
Once each activity, and resources, may declare a grouping to use, it is possible to make that those users that are not members of any group of that grouping cannot access to the module content (being it an interactive activity or a Resource module instance)
A simple checking for group membership at the beggining of the view.php file for each module would do the trick
Group-membership may be checked at course page (function print_section() ) to make links to forbidden modules invisible to users without suitable access.

At ULPGC we have a test site with these features ENABLED, that is, already coded. You may find it at http://moodle.ulpgc.es/moodle19ulpgc/course/view.php?id=3
Try login as user "prof01", "prof02" or "estudiante01", "estudiante02" ... with password "moodle" for all

The file attached is a unified diff against HEAD that can be used to explore proposed code changes.





 All   Comments   Change History   Version Control      Sort Order: Ascending order - Click to sort in descending order
Enrique Castro made changes - 09/Jul/07 07:09 AM
Field Original Value New Value
Link This issue duplicates MDL-8735 [ MDL-8735 ]
Enrique Castro made changes - 09/Jul/07 07:11 AM
Link This issue will help resolve MDL-8617 [ MDL-8617 ]
Enrique Castro made changes - 09/Jul/07 07:17 AM
Link This issue will help resolve MDL-8735 [ MDL-8735 ]
Enrique Castro made changes - 09/Jul/07 07:18 AM
Link This issue will help resolve MDL-7380 [ MDL-7380 ]
Helen Foster made changes - 12/Jul/07 06:06 PM
QA Assignee tsala
Petr Skoda made changes - 18/Jul/07 05:05 AM
Attachment groups.dia [ 11547 ]
Petr Skoda made changes - 19/Jul/07 01:01 AM
Attachment groups.dia [ 11547 ]
Petr Skoda made changes - 19/Jul/07 01:02 AM
Attachment groups.dia [ 11555 ]
Nick Freear made changes - 27/Jul/07 08:22 PM
Attachment patch-MDL-10383-groups-db-v6.diff [ 11597 ]
Nick Freear made changes - 27/Jul/07 08:26 PM
Attachment patch-Bugz-2617-group_cm.diff [ 11598 ]
Nick Freear made changes - 27/Jul/07 08:28 PM
Martin Dougiamas made changes - 09/Aug/07 01:54 PM
Assignee Nick Freear [ nfreear ] Petr Skoda [ skodak ]
Matt Clarkson made changes - 13/Aug/07 05:21 AM
Attachment groups-db-libchanges.diff [ 11672 ]
Petr Skoda made changes - 15/Aug/07 10:33 PM
Attachment groups_cleanup2.patch [ 11685 ]
Petr Skoda made changes - 17/Aug/07 07:52 PM
Link This issue is duplicated by MDL-8668 [ MDL-8668 ]
Petr Skoda made changes - 17/Aug/07 07:53 PM
Link This issue is duplicated by MDL-8668 [ MDL-8668 ]
Petr Skoda made changes - 17/Aug/07 07:53 PM
Link This issue is duplicated by MDL-8617 [ MDL-8617 ]
Petr Skoda made changes - 17/Aug/07 07:54 PM
Link This issue will help resolve MDL-8735 [ MDL-8735 ]
Petr Skoda made changes - 17/Aug/07 08:00 PM
Link This issue will be resolved by MDL-10888 [ MDL-10888 ]
Martin Dougiamas made changes - 23/Aug/07 03:13 PM
Fix Version/s 1.9 [ 10190 ]
Martin Dougiamas made changes - 12/Sep/07 02:52 PM
Status Open [ 1 ] Resolved [ 5 ]
Resolution Fixed [ 1 ]
Petr Skoda made changes - 29/Sep/07 09:45 PM
Status Resolved [ 5 ] Reopened [ 4 ]
Resolution Fixed [ 1 ]
Petr Skoda made changes - 29/Sep/07 09:49 PM
Resolution Fixed [ 1 ]
Status Reopened [ 4 ] Resolved [ 5 ]
Martin Dougiamas made changes - 03/Oct/07 05:13 PM
Status Resolved [ 5 ] Reopened [ 4 ]
Resolution Fixed [ 1 ]
Petr Skoda made changes - 03/Oct/07 05:46 PM
Status Reopened [ 4 ] Resolved [ 5 ]
Resolution Fixed [ 1 ]
Petr Skoda made changes - 03/Oct/07 11:52 PM
Link This issue will help resolve MDL-11574 [ MDL-11574 ]