From 3b3d3516c3725a0bc10b76ff8f0b63a50776b9ad Mon Sep 17 00:00:00 2001
From: Dominik George <dominik.george@teckids.org>
Date: Sun, 1 Sep 2019 21:08:41 +0200
Subject: [PATCH] Fix css decision for substition highlighting.

---
 biscuit/apps/chronos/tables.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/biscuit/apps/chronos/tables.py b/biscuit/apps/chronos/tables.py
index 3e797992..c1a55c4e 100644
--- a/biscuit/apps/chronos/tables.py
+++ b/biscuit/apps/chronos/tables.py
@@ -10,7 +10,7 @@ from .models import LessonPeriod
 
 
 def _css_class_from_lesson_state(record: Optional[LessonPeriod] = None, table: Optional[LessonsTable] = None) -> str:
-    if record.get_substitution(table._week):
+    if record.get_substitution(record._week):
         return 'table-warning'
     else:
         return ''
-- 
GitLab