Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #231 set objectid mapping to attendance id. #232

Merged
merged 1 commit into from Dec 1, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
9 changes: 9 additions & 0 deletions classes/event/attendance_taken.php
Expand Up @@ -89,6 +89,15 @@ protected function get_legacy_logdata() {
'', $this->contextinstanceid);
}

/**
* Get objectid mapping
*
* @return array of parameters for object mapping.
*/
public static function get_objectid_mapping() {
return array('db' => 'attendance', 'restore' => 'attendance');
}

/**
* Custom validation.
*
Expand Down
9 changes: 9 additions & 0 deletions classes/event/attendance_taken_by_student.php
Expand Up @@ -89,6 +89,15 @@ protected function get_legacy_logdata() {
'', $this->contextinstanceid);
}

/**
* Get objectid mapping
*
* @return array of parameters for object mapping.
*/
public static function get_objectid_mapping() {
return array('db' => 'attendance', 'restore' => 'attendance');
}

/**
* Custom validation.
*
Expand Down
10 changes: 10 additions & 0 deletions classes/event/report_viewed.php
Expand Up @@ -86,4 +86,14 @@ protected function get_legacy_logdata() {
return array($this->courseid, 'attendance', 'report', 'report.php?id=' . $this->objectid,
$this->objectid, $this->contextinstanceid);
}

/**
* Get objectid mapping
*
* @return array of parameters for object mapping.
*/
public static function get_objectid_mapping() {
return array('db' => 'attendance', 'restore' => 'attendance');
}

}
9 changes: 9 additions & 0 deletions classes/event/session_added.php
Expand Up @@ -87,6 +87,15 @@ protected function get_legacy_logdata() {
$this->other['info'], $this->contextinstanceid);
}

/**
* Get objectid mapping
*
* @return array of parameters for object mapping.
*/
public static function get_objectid_mapping() {
return array('db' => 'attendance', 'restore' => 'attendance');
}

/**
* Custom validation.
*
Expand Down
9 changes: 9 additions & 0 deletions classes/event/session_deleted.php
Expand Up @@ -87,6 +87,15 @@ protected function get_legacy_logdata() {
$this->other['info'], $this->contextinstanceid);
}

/**
* Get objectid mapping
*
* @return array of parameters for object mapping.
*/
public static function get_objectid_mapping() {
return array('db' => 'attendance', 'restore' => 'attendance');
}

/**
* Custom validation.
*
Expand Down
9 changes: 9 additions & 0 deletions classes/event/session_duration_updated.php
Expand Up @@ -87,6 +87,15 @@ protected function get_legacy_logdata() {
$this->other['info'], $this->contextinstanceid);
}

/**
* Get objectid mapping
*
* @return array of parameters for object mapping.
*/
public static function get_objectid_mapping() {
return array('db' => 'attendance', 'restore' => 'attendance');
}

/**
* Custom validation.
*
Expand Down
9 changes: 9 additions & 0 deletions classes/event/session_updated.php
Expand Up @@ -89,6 +89,15 @@ protected function get_legacy_logdata() {
$this->other['info'], $this->contextinstanceid);
}

/**
* Get objectid mapping
*
* @return array of parameters for object mapping.
*/
public static function get_objectid_mapping() {
return array('db' => 'attendance', 'restore' => 'attendance');
}

/**
* Custom validation.
*
Expand Down
10 changes: 10 additions & 0 deletions classes/event/status_added.php
Expand Up @@ -86,4 +86,14 @@ protected function get_legacy_logdata() {
return array($this->courseid, 'attendance', 'status added', $this->get_url(),
$this->other['acronym'].': '.$this->other['description'].' ('.$this->other['grade'].')', $this->contextinstanceid);
}

/**
* Get objectid mapping
*
* @return array of parameters for object mapping.
*/
public static function get_objectid_mapping() {
return array('db' => 'attendance', 'restore' => 'attendance');
}

}
10 changes: 10 additions & 0 deletions classes/event/status_removed.php
Expand Up @@ -88,4 +88,14 @@ protected function get_legacy_logdata() {
return array($this->courseid, 'attendance', 'status removed', $this->get_url(),
$this->other['acronym'] . ' - ' . $this->other['description'], $this->contextinstanceid);
}

/**
* Get objectid mapping
*
* @return array of parameters for object mapping.
*/
public static function get_objectid_mapping() {
return array('db' => 'attendance', 'restore' => 'attendance');
}

}
10 changes: 10 additions & 0 deletions classes/event/status_updated.php
Expand Up @@ -86,4 +86,14 @@ protected function get_legacy_logdata() {
return array($this->courseid, 'attendance', 'status updated', $this->get_url(),
$this->other['updated'], $this->contextinstanceid);
}

/**
* Get objectid mapping
*
* @return array of parameters for object mapping.
*/
public static function get_objectid_mapping() {
return array('db' => 'attendance', 'restore' => 'attendance');
}

}