Merge branch 'MDL-28387-master' of git://github.com/ankitagarwal/moodle
This commit is contained in:
+1
-1
@@ -29,7 +29,6 @@ defined('MOODLE_INTERNAL') || die();
|
||||
global $DB; // TODO: this is a hack, we should really do something with the SQL in SQL tables
|
||||
|
||||
$logs = array(
|
||||
array('module'=>'user', 'action'=>'view', 'mtable'=>'user', 'field'=>$DB->sql_concat('firstname', "' '" , 'lastname')),
|
||||
array('module'=>'course', 'action'=>'user report', 'mtable'=>'user', 'field'=>$DB->sql_concat('firstname', "' '" , 'lastname')),
|
||||
array('module'=>'course', 'action'=>'view', 'mtable'=>'course', 'field'=>'fullname'),
|
||||
array('module'=>'course', 'action'=>'update', 'mtable'=>'course', 'field'=>'fullname'),
|
||||
@@ -49,4 +48,5 @@ $logs = array(
|
||||
array('module'=>'group', 'action'=>'view', 'mtable'=>'groups', 'field'=>'name'),
|
||||
array('module'=>'tag', 'action'=>'update', 'mtable'=>'tag', 'field'=>'name'),
|
||||
array('module'=>'tag', 'action'=>'flag', 'mtable'=>'tag', 'field'=>'name'),
|
||||
array('module'=>'user', 'action'=>'view', 'mtable'=>'user', 'field'=>$DB->sql_concat('firstname', "' '" , 'lastname')),
|
||||
);
|
||||
|
||||
@@ -3880,6 +3880,9 @@ function delete_user($user) {
|
||||
$updateuser->timemodified = time();
|
||||
|
||||
$DB->update_record('user', $updateuser);
|
||||
// Add this action to log
|
||||
add_to_log(SITEID, 'user', 'delete', "view.php?id=$user->id", $user->firstname.' '.$user->lastname);
|
||||
|
||||
|
||||
// We will update the user's timemodified, as it will be passed to the user_deleted event, which
|
||||
// should know about this updated property persisted to the user's table.
|
||||
|
||||
Reference in New Issue
Block a user