Skip to content
Snippets Groups Projects
Verified Commit f6b81691 authored by Tom Teichler's avatar Tom Teichler :beers:
Browse files

Fix range of dates.

parent 36a1140f
No related branches found
No related tags found
No related merge requests found
...@@ -224,7 +224,7 @@ def manage_absence(request: HttpRequest) -> HttpResponse: ...@@ -224,7 +224,7 @@ def manage_absence(request: HttpRequest) -> HttpResponse:
# Mark person as absent # Mark person as absent
delta = end_date - start_date delta = end_date - start_date
for i in range(delta.days+1): for i in range(delta.days):
starting_period = starting_lesson if i == 0 else 0 starting_period = starting_lesson if i == 0 else 0
day = start_date + timedelta(days=1) day = start_date + timedelta(days=1)
person.mark_absent(day, starting_period=starting_period, absent=absent, excused=excused) person.mark_absent(day, starting_period=starting_period, absent=absent, excused=excused)
......
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