Skip to content

Commit

Permalink
Fix appointment popup mismatch by correcting ID generation (lanis-mob…
Browse files Browse the repository at this point in the history
  • Loading branch information
alessioC42 authored Nov 8, 2024
2 parents dd7b2a6 + 15740ef commit 525aed5
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions app/lib/view/timetable/view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class _StaticTimetableViewState extends State<StaticTimetableView> {
),
);
}

Widget getBody() {
if (widget.loading) {
return const Center(
Expand Down Expand Up @@ -201,7 +201,7 @@ class TimeTableDataSource extends CalendarDataSource {
location: lesson.raum,
notes: lesson.badge,
color: entryColor,
id: "${dayIndex - 1}-$lessonIndex-1"));
id: "${dayIndex}-${lessonIndex}-1"));

events.add(Appointment(
startTime: startTime,
Expand All @@ -210,7 +210,7 @@ class TimeTableDataSource extends CalendarDataSource {
location: lesson.raum,
notes: lesson.badge,
color: entryColor,
id: "${dayIndex - 1}-$lessonIndex-1"));
id: "${dayIndex}-${lessonIndex}-2"));

//1 week later
events.add(Appointment(
Expand All @@ -220,7 +220,7 @@ class TimeTableDataSource extends CalendarDataSource {
location: lesson.raum,
notes: lesson.lehrer,
color: entryColor,
id: "${dayIndex - 1}-$lessonIndex-2"));
id: "${dayIndex}-${lessonIndex}-3"));
}
}

Expand Down

0 comments on commit 525aed5

Please sign in to comment.