General plugins (Local): CSV Enrolls & Groups plugin

local_userenrols
Maintained by FredFred Woolard
Use this local plugin to import user enrollments and group assignments from a delimited text file into the course. New user accounts will not be created, so each of the users listed in the input file must already have an account set up in the site.
359 sites
296 downloads
23 fans
Current versions available: 4

The CSV Enrolls & Groups plugin allows you to import user enrollments for a course from an uploaded delimited text file. It is contributed by Fred Woolard.

Enrollments are made with the manual enrol plugin and using a selectable role. The plugin can optionally create course groups and assign the new enrollees to those groups.

Each of the users listed in the input file must have an existing Moodle user account; new Moodle user accounts will not be created.

This plugin was originally (Moodle 1.9) a refactor of the mass_enroll course admin mod done by Patrick Pollet and Valery Fremaux, using the standard groups course import plugin as a template. The current Moodle 2.x revision is again a refactor, but as a local plugin (placed into the local/ directory off the Moodle root), and accessed from the course administration menu under the 'Users' node.

Besides being able to create groups, you can select from existing groups and override the data file's group designation.

Screenshots

Screenshot #0

Contributors

Fred
Fred Woolard (Lead maintainer)
Please login to view contributors details and/or to contact them

Comments RSS

Show comments
  • Fred
    Mon, Aug 28, 2017, 8:04 PM
    Sergey... will respond to you with message.
  • Picture of Joyeux Eloise
    Wed, Sep 6, 2017, 5:43 PM
    Hi Fred! I also have a version 3.1 of moodle and we used the plugin in version 2.7. A version of the plugin for moodle v3.1 planned soon? ? Thank you in advance for your help !
  • Picture of Joseph Liaw
    Wed, Sep 13, 2017, 8:49 AM
    Hi Fred:
    Thanks for a FANTASTIC plugin that makes getting students enrolled and into groups into your courses! This also works fantastic for quickly creating groups for group assignments, and dovetails perfectly for the amazing Active Quiz plugin to quickly put your entire class into groups, and then allowing students to quickly self check-in who in their group is present for each session....

    Quick question: any chance you will be updating for Moodle 3.1 and 3.2 soon? Thanks for sharing your great work with the Moodle community!
  • Fred
    Fri, Sep 15, 2017, 9:59 PM
    Joyeux, and Josepth,

    Thank you both for your comments. The plugin version available on Moodle's download site should work on 3.1 or 3.2 without problem. There is a more current version on the github repository, however, please be forewarned that the current version removes functionality having to do with group assignments from metalink course enrollments. The functionality for group assignments from .csv file imports is still there.

    Because I do not know how many users would be impacted by removing the course metalink group assignment feature, I have not uploaded the current version to Moodle.
  • Picture of jon pullen
    Tue, Dec 5, 2017, 10:42 PM
    Hi Fred,

    Could you confirm that the ID Number field is limited to only numerical entries? (as the name suggests)
    Some of our users have alphanumeric IDs, causing the "unable to parse" message.

    Thanks in advance.
  • Fred
    Tue, Dec 5, 2017, 11:03 PM
    Jon, correct. The regex on line 218 of userenrols/lib.php controls, and can be edited if need be.
  • Andrew
    Wed, Feb 7, 2018, 12:26 AM
    Thanks for the plugin Fred. Would the new plugin version prevent me from grouping users already in a metacourse?
  • Fred
    Wed, Feb 7, 2018, 12:43 AM
    Andrew C, I removed that functionality (groups based on course meta link) because it was redundant, the feature is now available in the course meta link plugin. It does not prevent you from using the course meta link plugin 'Add to group' feature.
  • Picture of Mike Elliott
    Wed, Jul 25, 2018, 5:08 PM
    Hi Fred, Useful plugin- thanks! I can enrol people successfully using their usernames, but when I try and use email addresses I get a parsing error. Our company emails are a couple of subdomains deep, so I've replaced the regex with one that will match anything '/(.*?)'. I'm still getting the unable to parse error. Is there a way to fix this?
  • Fred
    Wed, Jul 25, 2018, 11:01 PM
    @MikeElliott, will send message.
  • myname
    Tue, Aug 28, 2018, 2:05 PM
    Hi,
    I have a question, I am using external DB plugin to enroll users
    if I use this plugin, does the enrolment method change from external DB to manual?
  • Fred
    Tue, Aug 28, 2018, 11:31 PM
    @moodle_question, this plugin will not change any existing user enrollments/roles they have in a course. If the user does not yet have a role in the course, it will add a manual enrollment for that user and make the specified role assignment. If the user already has a role in the course, no enrollment/role assignment will take place for that user; however, a group assignment may still take place if that is specified.
  • Picture of Joseph Liaw
    Sat, May 16, 2020, 6:34 AM
    Hi Fred: Any chance you will be update your fantastic plugin to Moodle 3.8 or 3.9? Now that it looks like we will be in remote learning longer during the pandemic, helping teachers to be able to quickly enroll and make new groups for their students using your amazing plugin is a great tool to help keep learning social in spite of being socially distant!!! Thanks Fred for sharing your great work with the Moodle community!
  • Fred
    Sun, May 17, 2020, 6:24 AM
    Joseph, I have tested the plugin with the current (3.9dev) branch, stepped through the debugger along with the Moodle DEVELOPER debug settings for verbose output, and appears to work correctly. So I will update the info in the plugin database to reflect compatibility through 3.9.
  • Picture of Joseph Liaw
    Mon, May 18, 2020, 6:12 AM
    Holy guacomole Batman that was fast!!! Thanks Fred--I know Moodle has been a godsend to our teachers and students doing remote learning during the pandemic, and your plugin has been invaluable for quickly getting students enrolled and into groups, which makes it easy for teachers to quickly build new groups for their students to make learning social (works great with the Group Quiz plugin for Team Based Learning!) and helps empower students to work together with their friends!! THANK YOU Fred!!!!
1 2
Please login to post comments