Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
nk20
Manage
Activity
Members
Labels
Plan
Issues
31
Issue boards
Milestones
Wiki
Code
Merge requests
7
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package 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
BDE
nk20
Commits
0d9891fb
Commit
0d9891fb
authored
7 months ago
by
bleizi
Browse files
Options
Downloads
Plain Diff
Merge branch 'migration-django-4-2' of gitlab.crans.org:bde/nk20 into migration-django-4-2
parents
96215cc1
bbbdcc72
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!230
nk20 v2.0.0 with django 4.2
Pipeline
#14089
passed with stages
in 21 minutes and 14 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
apps/note/api/views.py
+4
-13
4 additions, 13 deletions
apps/note/api/views.py
apps/registration/forms.py
+0
-10
0 additions, 10 deletions
apps/registration/forms.py
with
4 additions
and
23 deletions
apps/note/api/views.py
+
4
−
13
View file @
0d9891fb
...
...
@@ -179,19 +179,10 @@ class ConsumerViewSet(ReadOnlyProtectedModelViewSet):
# We match first an alias if it is matched without normalization,
# then if the normalized pattern matches a normalized alias.
queryset
=
queryset
.
filter
(
**
{
f
'
name
{
suffix
}
'
:
alias_prefix
+
alias
}
).
union
(
queryset
.
filter
(
Q
(
**
{
f
'
normalized_name
{
suffix
}
'
:
alias_prefix
+
Alias
.
normalize
(
alias
)})
&
~
Q
(
**
{
f
'
name
{
suffix
}
'
:
alias_prefix
+
alias
})
),
all
=
True
).
union
(
queryset
.
filter
(
Q
(
**
{
f
'
normalized_name
{
suffix
}
'
:
alias_prefix
+
alias
.
lower
()})
&
~
Q
(
**
{
f
'
normalized_name
{
suffix
}
'
:
alias_prefix
+
Alias
.
normalize
(
alias
)})
&
~
Q
(
**
{
f
'
name
{
suffix
}
'
:
alias_prefix
+
alias
})
),
all
=
True
)
Q
(
**
{
f
'
name
{
suffix
}
'
:
alias_prefix
+
alias
})
|
Q
(
**
{
f
'
normalized_name
{
suffix
}
'
:
alias_prefix
+
Alias
.
normalize
(
alias
)})
|
Q
(
**
{
f
'
normalized_name
{
suffix
}
'
:
alias_prefix
+
alias
.
lower
()})
)
queryset
=
queryset
if
settings
.
DATABASES
[
queryset
.
db
][
"
ENGINE
"
]
==
'
django.db.backends.postgresql
'
\
else
queryset
.
order_by
(
"
name
"
)
...
...
This diff is collapsed.
Click to expand it.
apps/registration/forms.py
+
0
−
10
View file @
0d9891fb
...
...
@@ -5,7 +5,6 @@ from django import forms
from
django.contrib.auth.forms
import
UserCreationForm
from
django.contrib.auth.models
import
User
from
django.utils.translation
import
gettext_lazy
as
_
from
member.models
import
Club
from
note.models
import
NoteSpecial
,
Alias
from
note_kfet.inputs
import
AmountInput
...
...
@@ -115,12 +114,3 @@ class ValidationForm(forms.Form):
required
=
False
,
initial
=
True
,
)
# If the bda exists
if
Club
.
objects
.
filter
(
name__iexact
=
"
bda
"
).
exists
():
# The user can join the bda club at the inscription
join_bda
=
forms
.
BooleanField
(
label
=
_
(
"
Join BDA Club
"
),
required
=
False
,
initial
=
True
,
)
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