Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
AlekSIS-App-Chronos
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
AlekSIS®
Official
AlekSIS-App-Chronos
Commits
a23a9462
Commit
a23a9462
authored
3 years ago
by
Jonathan Weth
Browse files
Options
Downloads
Patches
Plain Diff
Fix detection of the end of the validity ranges list in next_lessons
parent
96817b2a
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Pipeline
#17508
canceled
3 years ago
Stage: test
Stage: build
Stage: publish
Stage: docker
Stage: deploy
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
CHANGELOG.rst
+1
-0
1 addition, 0 deletions
CHANGELOG.rst
aleksis/apps/chronos/managers.py
+1
-1
1 addition, 1 deletion
aleksis/apps/chronos/managers.py
with
2 additions
and
1 deletion
CHANGELOG.rst
+
1
−
0
View file @
a23a9462
...
...
@@ -21,6 +21,7 @@ Fixed
user language (fixed by using gettext_lazy).
* Affected groups and persons in substitutions list were displayed multiple times.
* ``lessons_on_day`` didn't work as expected if a person has no lessons.
* End of validity ranges list wasn't detected correctly in ``next_lesson``.
`2.0b2` - 2021-06-02
--------------------
...
...
This diff is collapsed.
Click to expand it.
aleksis/apps/chronos/managers.py
+
1
−
1
View file @
a23a9462
...
...
@@ -465,7 +465,7 @@ class LessonDataQuerySet(models.QuerySet, WeekQuerySetMixin):
# If date of next lesson period is out of validity range (larger) ...
elif
next_lesson_period_date
>
next_lesson_period
.
lesson
.
validity
.
date_end
:
# ... we have to get the lesson period from the next validity range
if
validity_index
>=
len
(
validity_ranges
):
if
validity_index
>=
len
(
validity_ranges
)
-
1
:
# There are no validity ranges (and thus no lessons)
# in the school term after this lesson period
return
None
...
...
This diff is collapsed.
Click to expand it.
Jonathan Weth
@hansegucker
mentioned in commit
cb766968
·
3 years ago
mentioned in commit
cb766968
mentioned in commit cb766968cd92f625a91fd8d8ae3c76878760edf8
Toggle commit list
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment