MDL-19925 adding events to upload users scripts

This commit is contained in:
Petr Skoda
2010-10-09 22:53:50 +00:00
parent b68e1bc521
commit e6f74ba355
+4
View File
@@ -499,6 +499,8 @@ if ($formdata = $mform->is_cancelled()) {
$usersupdated++;
// save custom profile fields data from csv file
profile_save_data($existinguser);
events_trigger('user_updated', $existinguser);
}
if ($bulk == 2 or $bulk == 3) {
@@ -564,6 +566,8 @@ if ($formdata = $mform->is_cancelled()) {
// make sure user context exists
get_context_instance(CONTEXT_USER, $user->id);
events_trigger('user_created', $user);
if ($bulk == 1 or $bulk == 3) {
if (!in_array($user->id, $SESSION->bulk_users)) {
$SESSION->bulk_users[] = $user->id;