Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function bigbluebuttonbn_print_recent_activity(object $course, bool $viewfullnames, int $timestart): bool {
- global $OUTPUT;
- $modinfo = get_fast_modinfo($course);
- if (empty($modinfo->instances['bigbluebuttonbn'])) {
- return true;
- }
- foreach ($modinfo->instances['bigbluebuttonbn'] as $cm) {
- if (!$cm->uservisible) {
- continue;
- }
- $instance = instance::get_from_cmid($cm->id);
- $logs = logger::get_user_completion_logs_with_userfields($instance,
- null,
- [logger::EVENT_JOIN, logger::EVENT_PLAYED],
- $timestart);
- if ($logs) {
- echo $OUTPUT->heading(get_string('new_bigblubuttonbn_activities', 'bigbluebuttonbn') . ':', 6);
- foreach ($logs as $log) {
- $activityurl = new moodle_url('/mod/bigbluebuttonbn/index.php', ['id' => $instance->get_instance_id()]);
- print_recent_activity_note($log->timecreated,
- $log,
- logger::get_printable_event_name($log) . ' - '. $instance->get_meeting_name(),
- $activityurl->out(),
- false,
- $viewfullnames);
- }
- }
- }
- return true;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement