Skip to content
Snippets Groups Projects
Commit 00f71dad authored by Moritz Strohm's avatar Moritz Strohm
Browse files

fixed saving of calendar dates for course calendars

parent 95eb0337
No related branches found
No related tags found
No related merge requests found
......@@ -514,6 +514,9 @@ class Calendar_DateController extends AuthenticatedController
if (($owner instanceof Course)) {
//Set the course as calendar:
$allowed_calendar_ids = [$owner->id];
} elseif (Context::isCourse()) {
//Set the course as allowed calendar:
$allowed_calendar_ids = [Context::getId()];
} else {
//Assign the date to the calendars of all the selected users:
$allowed_calendar_ids = [$GLOBALS['user']->id];
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment