mirror of
https://github.com/moodle/moodle.git
synced 2025-08-08 10:26:40 +02:00
Merge branch 'MDL-45607_m26' of https://github.com/markn86/moodle into MOODLE_26_STABLE
This commit is contained in:
commit
9832d18ab5
2 changed files with 6 additions and 5 deletions
|
@ -54,7 +54,7 @@ class user_profile_viewed extends base {
|
|||
*/
|
||||
public function get_description() {
|
||||
return 'User ' . $this->userid . ' viewed the profile for user ' . $this->relateduserid . ' in the course ' .
|
||||
$this->other['courseid'];
|
||||
$this->courseid;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -63,7 +63,7 @@ class user_profile_viewed extends base {
|
|||
* @return \moodle_url
|
||||
*/
|
||||
public function get_url() {
|
||||
return new \moodle_url('/user/view.php', array('id' => $this->relateduserid, 'course' => $this->other['courseid']));
|
||||
return new \moodle_url('/user/view.php', array('id' => $this->relateduserid, 'course' => $this->courseid));
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -72,7 +72,7 @@ class user_profile_viewed extends base {
|
|||
* @return array
|
||||
*/
|
||||
protected function get_legacy_logdata() {
|
||||
return array($this->other['courseid'], 'user', 'view', 'view.php?id=' . $this->relateduserid . '&course=' .
|
||||
$this->other['courseid'], $this->relateduserid);
|
||||
return array($this->courseid, 'user', 'view', 'view.php?id=' . $this->relateduserid . '&course=' .
|
||||
$this->courseid, $this->relateduserid);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -191,7 +191,8 @@ if ($user->deleted) {
|
|||
$event = \core\event\user_profile_viewed::create(array(
|
||||
'objectid' => $USER->id,
|
||||
'relateduserid' => $user->id,
|
||||
'context' => $usercontext,
|
||||
'courseid' => $course->id,
|
||||
'context' => $coursecontext,
|
||||
'other' => array(
|
||||
'courseid' => $course->id,
|
||||
'courseshortname' => $course->shortname,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue