Skip to content
Snippets Groups Projects
Commit ea611ecd authored by Jan-Hendrik Willms's avatar Jan-Hendrik Willms
Browse files

fixes #3940

Closes #3940

Merge request studip/studip!2799
parent 8fcf1bd1
No related branches found
No related tags found
No related merge requests found
...@@ -91,17 +91,16 @@ class Calendar_ContentboxController extends StudipController ...@@ -91,17 +91,16 @@ class Calendar_ContentboxController extends StudipController
private function parseSeminar($id) private function parseSeminar($id)
{ {
$course = Course::find($id); // Display only date and time if in course range, include course title
$this->termine = $course->getDatesWithExdates()->findBy('end_time', [$this->start, $this->start + $this->timespan], '><'); // otherwise
foreach ($this->termine as $course_date) { $date_format = $this->course_range ? 'include-room' : 'verbose';
if ($this->course_range) {
//Display only date and time: $this->termine = Course::find($id)->getDatesWithExdates()
$this->titles[$course_date->id] = $course_date->getFullName('include-room'); ->findBy('end_time', [$this->start, $this->start + $this->timespan], '><')
} else { ->map(function ($course_date) use ($date_format) {
//Include the course title: $this->titles[$course_date->id] = $course_date->getFullName($date_format);
$this->titles[$course_date->id] = $course_date->getFullName('verbose'); return $course_date;
} });
}
} }
private function parseUser($id) private function parseUser($id)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment