Auto assign cohort (deprecated for local_cohortauto)

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

Supports Moodle 2.0-3.0 See all versions
Latest release: 10 years ago
Installations: 142
Downloads (last 90 days): 22

Frankenstyle name: auth_mcae
Authentication

Comments

Comments are no longer open for new posts. Existing comments remain available to read.

I added the line:
require_once($CFG->dirroot.'/user/profile/lib.php');
at the vry beginning of auth/mcae/auth.php
and it works now!
PS the code was added at the very beginning of the file.
Hello,
I get the following error message:
Fatal error: Call to undefined function profile_load_data() in [...]/auth/mcae/auth.php on line 227
with moodle 2.2+ and the decaf theme.
A stated in the readme file, in moodle/themes/decaf/layout/general.php, I added the code <?php
global $SESSION, $USER;
if ($USER->id != 0) { // Only for autenticated users
$mcae = get_auth_plugin('mcae'); //Get mcae plugin
if (isset($SESSION->mcautoenrolled)) {
if (!$SESSION->mcautoenrolled) {
$mcae->user_authenticated_hook($USER,$USER->username,""); //Autoenrol if mcautoenrolled FALSE
}
} else {
$mcae->user_authenticated_hook($USER,$USER->username,""); //Autoenrol if mcautoenrolled NOT SET
}
}
?>
Please help!
The plugin pulls data from the tables mdl_user and mdl_user_info_data
I use user upload function to create or update user accounts and http://moodle.org/plugins/view.php?plugin=local_user_bulk_editor to create cohorts
Is there anyway to pull the cohorts from the enrollment table? I am confused by creating custom fields in the profile for what is already course and role - how do you populate these fields? Do you link them to the course enrollment table?
Hi Andrew, we're interested in creating cohorts from our 2000+ users based on their country, but using this to actually assign them to a group in each course so instructors can followup on student progress country by country. Is this something which your plugin can help in doing?
Hey Andrew,
Okay so i installed the plug in and it works great! Except that it only works after the second log in. I saw in the read me for us to insert a .php coding into the server to possibly fix this problem? We tried that and it did not work. Is there a specific place we have to put that coding in or do we just insert it anywhere?
also by anychance would you know how to edit the email confirmation message moodle sends when a new user registers via email?
Any help would be great thank you!
I can not reproduce this error.
Tested on:
moodle 2.1.5+ (Build: 20120412)
moodle 2.2.2+ (Build: 20120412)
mcae 2012040219
server OS: win2003 server
apache: 2.2.15
php: 5.3.2
Debug msg: DEVELOPER
Show origin of languages strings: on
Show page information: on
With debug mode enabled, I'm getting some missing string notices, even though the strings are in the language file:
Invalid get_string() identifier: 'pluginname' or component 'auth_mcae'. Perhaps you are missing $string['pluginname'] = ''; in /var/www/vhosts/s2learning.net/httpdocs/vans/lms/auth/mcae/lang/en/auth_mcae.php?
line 6386 of /lib/moodlelib.php: call to debugging()
line 6978 of /lib/moodlelib.php: call to core_string_manager->get_string()
line 99 of /admin/settings/plugins.php: call to get_string()
line 5933 of /lib/adminlib.php: call to require()
line 3015 of /lib/navigationlib.php: call to admin_get_root()
line 2923 of /lib/navigationlib.php: call to settings_navigation->load_administration_settings()
line 601 of /lib/pagelib.php: call to settings_navigation->initialise()
line 617 of /lib/pagelib.php: call to moodle_page->magic_get_settingsnav()
line 2679 of /lib/navigationlib.php: call to moodle_page->__get()
line 659 of /lib/pagelib.php: call to navbar->has_items()
line 4 of /theme/base/layout/general.php: call to moodle_page->has_navbar()
line 685 of /lib/outputrenderers.php: call to include()
line 637 of /lib/outputrenderers.php: call to core_renderer->render_page_layout()
line 62 of /backup/restore.php: call to core_renderer->header()
Invalid get_string() identifier: 'auth_cohorttoolmcae' or component 'auth_mcae'. Perhaps you are missing $string['auth_cohorttoolmcae'] = ''; in /var/www/vhosts/s2learning.net/httpdocs/vans/lms/auth/mcae/lang/en/auth_mcae.php?
line 6386 of /lib/moodlelib.php: call to debugging()
line 6978 of /lib/moodlelib.php: call to core_string_manager->get_string()
line 20 of /auth/mcae/settings.php: call to get_string()
line 105 of /admin/settings/plugins.php: call to include()
line 5933 of /lib/adminlib.php: call to require()
line 3015 of /lib/navigationlib.php: call to admin_get_root()
line 2923 of /lib/navigationlib.php: call to settings_navigation->load_administration_settings()
line 601 of /lib/pagelib.php: call to settings_navigation->initialise()
line 617 of /lib/pagelib.php: call to moodle_page->magic_get_settingsnav()
line 2679 of /lib/navigationlib.php: call to moodle_page->__get()
line 659 of /lib/pagelib.php: call to navbar->has_items()
line 4 of /theme/base/layout/general.php: call to moodle_page->has_navbar()
line 685 of /lib/outputrenderers.php: call to include()
line 637 of /lib/outputrenderers.php: call to core_renderer->render_page_layout()
line 62 of /backup/restore.php: call to core_renderer->header()
Invalid get_string() identifier: 'auth_cohortviewmcae' or component 'auth_mcae'. Perhaps you are missing $string['auth_cohortviewmcae'] = ''; in /var/www/vhosts/s2learning.net/httpdocs/vans/lms/auth/mcae/lang/en/auth_mcae.php?
line 6386 of /lib/moodlelib.php: call to debugging()
line 6978 of /lib/moodlelib.php: call to core_string_manager->get_string()
line 24 of /auth/mcae/settings.php: call to get_string()
line 105 of /admin/settings/plugins.php: call to include()
line 5933 of /lib/adminlib.php: call to require()
line 3015 of /lib/navigationlib.php: call to admin_get_root()
line 2923 of /lib/navigationlib.php: call to settings_navigation->load_administration_settings()
line 601 of /lib/pagelib.php: call to settings_navigation->initialise()
line 617 of /lib/pagelib.php: call to moodle_page->magic_get_settingsnav()
line 2679 of /lib/navigationlib.php: call to moodle_page->__get()
line 659 of /lib/pagelib.php: call to navbar->has_items()
line 4 of /theme/base/layout/general.php: call to moodle_page->has_navbar()
line 685 of /lib/outputrenderers.php: call to include()
line 637 of /lib/outputrenderers.php: call to core_renderer->render_page_layout()
line 62 of /backup/restore.php: call to core_renderer->header()
This is a great plugin! Simple to use and very powerful. Thank you