Skip to content

Commit

Permalink
Merge pull request #451 from nstefanski/nstefanski-patch-events
Browse files Browse the repository at this point in the history
patch events for My Overview
  • Loading branch information
jrchamp authored Mar 30, 2023
2 parents 6673a2d + 0346c83 commit b2515d2
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -676,12 +676,16 @@ function mod_zoom_core_calendar_provide_event_action(calendar_event $event,
$zoom = $DB->get_record('zoom', ['id' => $cm->instance], '*');
list($inprogress, $available, $finished) = zoom_get_state($zoom);

return $factory->create_instance(
get_string('join_meeting', 'zoom'),
new \moodle_url('/mod/zoom/view.php', ['id' => $cm->id]),
1,
$available
);
if ($finished) {
return null; // No point to showing finished meetings in overview.
} else {
return $factory->create_instance(
get_string('join_meeting', 'zoom'),
new \moodle_url('/mod/zoom/view.php', ['id' => $cm->id]),
1,
$available
);
}
}

/* Gradebook API */
Expand Down

0 comments on commit b2515d2

Please sign in to comment.