Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
U
Učebnice
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
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
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
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TO
Učebnice
Commits
12126a6a
Commit
12126a6a
authored
4 months ago
by
Alexa Valentová
Browse files
Options
Downloads
Patches
Plain Diff
fix lecture query
parent
5565b811
No related branches found
Branches containing commit
No related tags found
1 merge request
!2
Release
Pipeline
#20131
passed
4 months ago
Stage: build
Stage: test_deploy
Changes
5
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
.gitignore
+1
-0
1 addition, 0 deletions
.gitignore
env.example
+1
-1
1 addition, 1 deletion
env.example
lectures/models.py
+1
-1
1 addition, 1 deletion
lectures/models.py
manage.py
+1
-1
1 addition, 1 deletion
manage.py
ucebnice/asgi.py
+1
-1
1 addition, 1 deletion
ucebnice/asgi.py
with
5 additions
and
4 deletions
.gitignore
+
1
−
0
View file @
12126a6a
...
...
@@ -7,3 +7,4 @@ shared/static/shared/*.js
shared/static/shared/*.css
shared/static/shared/*.txt
media/*
.venv
\ No newline at end of file
This diff is collapsed.
Click to expand it.
env.example
+
1
−
1
View file @
12126a6a
...
...
@@ -2,7 +2,7 @@ DATABASE_URL="postgresql://ucebnice:ucebnice@localhost:5432/ucebnice"
SECRET_KEY=supersecret
SITE_URL="http://localhost:801
3
"
SITE_URL="http://localhost:801
4
"
OIDC_RP_REALM_URL="http://localhost:8080/realms/master/"
OIDC_RP_CLIENT_ID=ucebnice
...
...
This diff is collapsed.
Click to expand it.
lectures/models.py
+
1
−
1
View file @
12126a6a
...
...
@@ -182,7 +182,7 @@ class Lecture(NameStrMixin, models.Model):
return
LectureGroupType
.
objects
.
filter
(
lecture
=
self
,
group__in
=
(
LectureGroup
.
filter
(
LectureGroup
.
objects
.
filter
(
models
.
Q
(
user_groups__in
=
request
.
user
.
groups
.
all
())
if
not
request
.
user
.
is_superuser
else
models
.
Q
(
id__isnull
=
False
)
# Always True
...
...
This diff is collapsed.
Click to expand it.
manage.py
+
1
−
1
View file @
12126a6a
...
...
@@ -6,7 +6,7 @@ import sys
def
main
():
"""
Run administrative tasks.
"""
os
.
environ
.
setdefault
(
"
DJANGO_SETTINGS_MODULE
"
,
"
ucebnice.settings
"
)
os
.
environ
.
setdefault
(
"
DJANGO_SETTINGS_MODULE
"
,
"
ucebnice.settings
.dev
"
)
try
:
from
django.core.management
import
execute_from_command_line
except
ImportError
as
exc
:
...
...
This diff is collapsed.
Click to expand it.
ucebnice/asgi.py
+
1
−
1
View file @
12126a6a
...
...
@@ -11,6 +11,6 @@ import os
from
django.core.asgi
import
get_asgi_application
os
.
environ
.
setdefault
(
"
DJANGO_SETTINGS_MODULE
"
,
"
registry
.settings
"
)
os
.
environ
.
setdefault
(
"
DJANGO_SETTINGS_MODULE
"
,
"
ucebnice
.settings
.dev
"
)
application
=
get_asgi_application
()
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