dart format

This commit is contained in:
2026-05-08 20:12:40 +02:00
parent 9e139b5704
commit 3b8da1d3d6
295 changed files with 6404 additions and 4161 deletions
@@ -20,10 +20,17 @@ class LessonStatusClassifier {
}) {
if (lesson.code == 'cancelled') return LessonStatus.cancelled;
if (isEvent) return LessonStatus.event;
if (lesson.code == 'irregular' || (lesson.te.isNotEmpty && lesson.te.first.id == 0)) return LessonStatus.irregular;
if (lesson.te.any((t) => t.orgname != null)) return LessonStatus.teacherChanged;
if (lesson.code == 'irregular' ||
(lesson.te.isNotEmpty && lesson.te.first.id == 0)) {
return LessonStatus.irregular;
}
if (lesson.te.any((t) => t.orgname != null)) {
return LessonStatus.teacherChanged;
}
if (endTime.isBefore(now)) return LessonStatus.past;
if (startTime.isBefore(now) && endTime.isAfter(now)) return LessonStatus.ongoing;
if (startTime.isBefore(now) && endTime.isAfter(now)) {
return LessonStatus.ongoing;
}
return LessonStatus.regular;
}
}