Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-22927

cannot make groups from added cohorts

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.0
    • Fix Version/s: 2.0
    • Component/s: Enrolments, Groups
    • Labels:
      None
    • Environment:
      Moodle 2.0 QA site
    • Affected Branches:
      MOODLE_20_STABLE
    • Fixed Branches:
      MOODLE_20_STABLE

      Description

      As mentioned in the forum here http://moodle.org/mod/forum/discuss.php?d=152791&parent=668298#p668519
      I made a cohort, enrolled the cohort into a course but there was no option then to make a group of the whole cohort. See file attached

        Gliffy Diagrams

          Issue Links

            Activity

            Hide
            dougiamas Martin Dougiamas added a comment -

            We just need a little menu on the cohort enrolment forms showing all the course groups, and a place to remember the relationship for future updates.

            Show
            dougiamas Martin Dougiamas added a comment - We just need a little menu on the cohort enrolment forms showing all the course groups, and a place to remember the relationship for future updates.
            Hide
            skodak Petr Skoda added a comment -

            This is not as easy as it looks, because users defined in the cohort must be enrolled first, only then we can start putting them to groups.
            The other problem is that it would require quite extensive changes in the user selector widget.

            I personally think this could be in fact also part of the new enrolment UI

            Another new feature could by part of the cohort synchronisation plugin, but it would require changes in the groups table because we would need component and itemid there in order to prevent the group assignments from random modifications.

            In any case at the moment the consistent sync between group and cohort is technically not possible.

            Show
            skodak Petr Skoda added a comment - This is not as easy as it looks, because users defined in the cohort must be enrolled first, only then we can start putting them to groups. The other problem is that it would require quite extensive changes in the user selector widget. I personally think this could be in fact also part of the new enrolment UI Another new feature could by part of the cohort synchronisation plugin, but it would require changes in the groups table because we would need component and itemid there in order to prevent the group assignments from random modifications. In any case at the moment the consistent sync between group and cohort is technically not possible.
            Hide
            skodak Petr Skoda added a comment -

            Ahh, I have completely forgotten that I already added support for creation of groups from cohorts, see the "Select members from cohort" option in the "Auto-create groups" interface

            I agree the usability of group/cohort UI could be improved a lot, but unfortunately we do not have much time before the release

            Thanks for the report...

            Show
            skodak Petr Skoda added a comment - Ahh, I have completely forgotten that I already added support for creation of groups from cohorts, see the "Select members from cohort" option in the "Auto-create groups" interface I agree the usability of group/cohort UI could be improved a lot, but unfortunately we do not have much time before the release Thanks for the report...
            Hide
            jmark93 Mark McCall added a comment -

            This issue needs to be reopened. The UI is there to create groups; however, it is not creating members from the selected cohort. In Moodle 2.0 Preview 4+ (Build: 20100715) it is auto-creating groups from the entire course enrollment.

            Show
            jmark93 Mark McCall added a comment - This issue needs to be reopened. The UI is there to create groups; however, it is not creating members from the selected cohort. In Moodle 2.0 Preview 4+ (Build: 20100715) it is auto-creating groups from the entire course enrollment.
            Hide
            skodak Petr Skoda added a comment -

            strange, the group creation from cohort works fine for me, both preview step and final group members, please file a new issue with the exact steps how to replicate the problem if necessary, thank you

            Petr

            Show
            skodak Petr Skoda added a comment - strange, the group creation from cohort works fine for me, both preview step and final group members, please file a new issue with the exact steps how to replicate the problem if necessary, thank you Petr
            Hide
            ppollet Patrick Pollet added a comment -

            >Petr said :

            >I agree the usability of group/cohort UI could be improved a lot,

            And also this requires the teacher to make two operations :

            1) add a new enrolment method (Cohort sync) and let it runs
            2) go to groups, create groups automatically and fill in the fields (some of them being confusing)

            and repeat step 2 at every modification of the associated cohort ... quite difficult if cohorts are synched nightly against an LDAP server.

            The attached patch modify the plugin enrol/cohort to allow automagic creation of group, and eventually grouping with the same name( or idnumber) of the associated cohort.

            1) admin defines the default values in settings.php
            2) teacher keeps or not these default values in addinstance_form.php/addinstance.php
            3) automagic creation/synching is done in locallib.php enrol_cohort_sync function, so it is done either manually where the teacher add a new cohort enrolment method or during the enrol_cohort cron() operation.

            Tested here with cohorts from 2 to 789 members .

            Enjoy

            Show
            ppollet Patrick Pollet added a comment - >Petr said : >I agree the usability of group/cohort UI could be improved a lot, And also this requires the teacher to make two operations : 1) add a new enrolment method (Cohort sync) and let it runs 2) go to groups, create groups automatically and fill in the fields (some of them being confusing) and repeat step 2 at every modification of the associated cohort ... quite difficult if cohorts are synched nightly against an LDAP server. The attached patch modify the plugin enrol/cohort to allow automagic creation of group, and eventually grouping with the same name( or idnumber) of the associated cohort. 1) admin defines the default values in settings.php 2) teacher keeps or not these default values in addinstance_form.php/addinstance.php 3) automagic creation/synching is done in locallib.php enrol_cohort_sync function, so it is done either manually where the teacher add a new cohort enrolment method or during the enrol_cohort cron() operation. Tested here with cohorts from 2 to 789 members . Enjoy
            Hide
            ppollet Patrick Pollet added a comment -

            Patched files are

            RCS file: /cvsroot/moodle/moodle/enrol/cohort/addinstance.php,v
            RCS file: /cvsroot/moodle/moodle/enrol/cohort/addinstance_form.php,v
            RCS file: /cvsroot/moodle/moodle/enrol/cohort/locallib.php,v
            RCS file: /cvsroot/moodle/moodle/enrol/cohort/settings.php,v
            RCS file: /cvsroot/moodle/moodle/enrol/cohort/version.php,v
            RCS file: /cvsroot/moodle/moodle/enrol/cohort/lang/en/enrol_cohort.php,v

            Show
            ppollet Patrick Pollet added a comment - Patched files are RCS file: /cvsroot/moodle/moodle/enrol/cohort/addinstance.php,v RCS file: /cvsroot/moodle/moodle/enrol/cohort/addinstance_form.php,v RCS file: /cvsroot/moodle/moodle/enrol/cohort/locallib.php,v RCS file: /cvsroot/moodle/moodle/enrol/cohort/settings.php,v RCS file: /cvsroot/moodle/moodle/enrol/cohort/version.php,v RCS file: /cvsroot/moodle/moodle/enrol/cohort/lang/en/enrol_cohort.php,v
            Hide
            tsala Helen Foster added a comment -

            Patrick, thanks for your patch. Reopening this issue...

            Show
            tsala Helen Foster added a comment - Patrick, thanks for your patch. Reopening this issue...
            Hide
            skodak Petr Skoda added a comment -

            Please file a new issue instead, because this looks like a new feature. The problem is that in order to make this reliable we would have to add new columns into the group table which would allow blocking of manual group modifications.

            Thanks for the patch.

            Petr

            Show
            skodak Petr Skoda added a comment - Please file a new issue instead, because this looks like a new feature. The problem is that in order to make this reliable we would have to add new columns into the group table which would allow blocking of manual group modifications. Thanks for the patch. Petr
            Hide
            ppollet Patrick Pollet added a comment -

            >The problem is that in order to make this reliable we would have to add new columns into the group table which would allow blocking of manual group modifications.

            I am not sure of this. In my place we do have course's groups containing a majority of members from a cohort extracted from LDAP or other source plus few extra participants , coming for example from paying participants manually added to Moodle and not registered in the University central LDAP, or some others coming from other departments but not members of the official cohort. They have been enroled in the course by some way (manually, self registration with a key ...)and manually added to some group by the teacher and they should stay in the group even if the group is meant to be mostly for official students.

            The beauty of Moodle 2.0 enrolment is that an user can be enroled in a course in several ways and will stay in that course as long as he has on enrolment method active. We should no redo the mistake of metacourses where is was impossible to have extra students not belonging to parent courses.

            So if we block manual group modifications, it will be impossible to have these 'unconventional members' in the course. I think that automatic sync of course groups from cohorts should be a 'convenience only' feature for teacher to stay tuned with the central University database ; but it should not prevent him to add extra members.

            BTW if he do remove some of the 'official members' from the group , they will be added again at the next nighlty sync... so he will get the point quickly

            Show
            ppollet Patrick Pollet added a comment - >The problem is that in order to make this reliable we would have to add new columns into the group table which would allow blocking of manual group modifications. I am not sure of this. In my place we do have course's groups containing a majority of members from a cohort extracted from LDAP or other source plus few extra participants , coming for example from paying participants manually added to Moodle and not registered in the University central LDAP, or some others coming from other departments but not members of the official cohort. They have been enroled in the course by some way (manually, self registration with a key ...)and manually added to some group by the teacher and they should stay in the group even if the group is meant to be mostly for official students. The beauty of Moodle 2.0 enrolment is that an user can be enroled in a course in several ways and will stay in that course as long as he has on enrolment method active. We should no redo the mistake of metacourses where is was impossible to have extra students not belonging to parent courses. So if we block manual group modifications, it will be impossible to have these 'unconventional members' in the course. I think that automatic sync of course groups from cohorts should be a 'convenience only' feature for teacher to stay tuned with the central University database ; but it should not prevent him to add extra members. BTW if he do remove some of the 'official members' from the group , they will be added again at the next nighlty sync... so he will get the point quickly
            Hide
            mediamarc Marc Malik added a comment -

            I'd like to follow up on this issue.

            Will the consistent sync between cohorts and groups be implemented in the Moodle 2.0 (RC) release? I always thought it's a feature of 2.0. (http://docs.moodle.org/en/Development:Cohorts)
            In my point of view this has great effect on the advantages of cohorts. Imagine a large number of cohorts with a lot of members and the corresponding groups.

            Show
            mediamarc Marc Malik added a comment - I'd like to follow up on this issue. Will the consistent sync between cohorts and groups be implemented in the Moodle 2.0 (RC) release? I always thought it's a feature of 2.0. ( http://docs.moodle.org/en/Development:Cohorts ) In my point of view this has great effect on the advantages of cohorts. Imagine a large number of cohorts with a lot of members and the corresponding groups.
            Hide
            skodak Petr Skoda added a comment -

            I am sorry, no more features are planned for 2.0 release.

            Show
            skodak Petr Skoda added a comment - I am sorry, no more features are planned for 2.0 release.
            Hide
            mediamarc Marc Malik added a comment -

            I filed an new issue: MDL-31437

            Show
            mediamarc Marc Malik added a comment - I filed an new issue: MDL-31437

              People

              • Votes:
                1 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  24/Nov/10