only show homework with deadline after today

This commit is contained in:
Kima 2024-01-25 19:24:41 +01:00
parent 4ed3cfc90e
commit a061ebd1e9

View File

@ -128,7 +128,9 @@ class GradesPageState extends State<GradesPage> {
i++; i++;
int homeworkCount = homeworkProvider.homework int homeworkCount = homeworkProvider.homework
.where((e) => e.subject.id == subject.id) .where((e) =>
e.subject.id == subject.id &&
e.deadline.isBefore(DateTime.now()))
.length; .length;
bool hasHomework = homeworkCount > 0; bool hasHomework = homeworkCount > 0;