Auto assign cohort (deprecated for local_cohortauto)

Authentication ::: auth_mcae
Maintained by Dan Marsden, Catalyst IT
This Authentication plugin automatically assigns users into cohorts based on information in their user profile fields.

Auto assign cohort (deprecated for local_cohortauto) 0.2

Moodle 2.0, 2.1, 2.2
Released: Thursday, 15 December 2011, 2:53 PM
This Authentication plugin automatically enrol users into cohorts.

Cohort name depends on user profile field.

How to use:

1. Copy plugin into /moodle/auth directory
2. Go to Site administration - Notifications page and install it
3. Go to Plugins - Authentication and enable plugin
4. Configure main rules (template for cohort name)
second rule (replace empty field)
and replacement array
5. ???
6. PROFIT

Cohorts are created in CONTEXT_SYSTEM

EXAMPLE:
You have a custom profile fields "status" (student, teacher or admin) and "course".

You wnat to enrol many users into cohorts like "course - status" than enrol cohorts into courses.

At configuration page set:
Main template to %profile_field_course - %profile_field_status (1 template per line, before profile fields type %)
Empty field text (When field is empty this value used) to none

Result:
When 1st course student logins, he enrol to cohort named "1 - student"
When 1st course teacher logins, he enrol to cohort named "1 - teacher"
When admin logins, he enrol to cohort named "none - admin" (Course not set, status - admin)

To rename "none - admin" cohort to "Administration" you must set a replacement array field at the configuration page (1 replacement per line, old_value|new_value)
In our case: none - admin|Administrator

Result:
When admin logins, he enrol to cohort named "Administrator"

-------
This plugin only create cohorts and enrol users to it.
To find the list of profile fields go to User - > User bulk operation and download 1-2 users.

Version information

Version build number
2011121500
Version release name
0.2
Can be updated from
0.1 (2011112700)
Can be updated to
0.3, 0.31 (2012040219), 0.4 (2012050512), 1.0 (2013051812)
Maturity
Release candidate
MD5 Sum
405b3ecca394bdac1be64a48a174d616
Supported software
Moodle 2.1, Moodle 2.0, PHP 5.3, Moodle 2.2

Default installation instructions for plugins of the type Authentication

  1. Make sure you have all the required versions.
  2. Download and unpack the module.
  3. Place the folder (eg "myauth") in the "auth" subdirectory.
  4. Visit http://yoursite.com/admin to finish the installation