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
62ec2838
Verified
Commit
62ec2838
authored
4 years ago
by
Jonathan Weth
Browse files
Options
Downloads
Patches
Plain Diff
Unify API of lesson period with event and extra lesson by adding properties for group names
parent
cdbbd954
No related branches found
No related tags found
1 merge request
!139
Unify API of lesson period with event and extra lesson by adding properties for group names
Pipeline
#6530
passed
4 years ago
Stage: test
Stage: build
Stage: publish
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
aleksis/apps/chronos/models.py
+10
-0
10 additions, 0 deletions
aleksis/apps/chronos/models.py
with
10 additions
and
0 deletions
aleksis/apps/chronos/models.py
+
10
−
0
View file @
62ec2838
...
...
@@ -473,6 +473,16 @@ class LessonPeriod(WeekAnnotationMixin, TeacherPropertiesMixin, ExtensibleModel)
def
get_groups
(
self
)
->
models
.
query
.
QuerySet
:
return
self
.
lesson
.
groups
@property
def
group_names
(
self
):
"""
Get group names as joined string.
"""
return
self
.
lesson
.
group_names
@property
def
group_short_names
(
self
):
"""
Get group short names as joined string.
"""
return
self
.
lesson
.
group_short_names
def
__str__
(
self
)
->
str
:
return
f
"
{
self
.
period
}
,
{
self
.
lesson
}
"
...
...
This diff is collapsed.
Click to expand it.
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