mirror of
https://gitlab.crans.org/bde/nk20
synced 2025-06-13 13:27:29 +02:00
linters
This commit is contained in:
parent
4479e8f97a
commit
02453e07ba
@ -39,9 +39,11 @@ class WEIRegistrationForm(forms.ModelForm):
|
|||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
model = WEIRegistration
|
model = WEIRegistration
|
||||||
fields = ['user', 'soge_credit', 'birth_date', 'gender', 'clothing_size',
|
fields = [
|
||||||
'health_issues', 'emergency_contact_name', 'emergency_contact_phone', 'first_year',
|
'user', 'soge_credit', 'birth_date', 'gender', 'clothing_size',
|
||||||
'information_json']
|
'health_issues', 'emergency_contact_name', 'emergency_contact_phone',
|
||||||
|
'first_year', 'information_json', 'caution_check'
|
||||||
|
]
|
||||||
widgets = {
|
widgets = {
|
||||||
"user": Autocomplete(
|
"user": Autocomplete(
|
||||||
User,
|
User,
|
||||||
@ -51,8 +53,14 @@ class WEIRegistrationForm(forms.ModelForm):
|
|||||||
'placeholder': 'Nom ...',
|
'placeholder': 'Nom ...',
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
"birth_date": DatePickerInput(options={'minDate': '1900-01-01',
|
"birth_date": DatePickerInput(options={
|
||||||
'maxDate': '2100-01-01'}),
|
'minDate': '1900-01-01',
|
||||||
|
'maxDate': '2100-01-01'
|
||||||
|
}),
|
||||||
|
"caution_check": forms.BooleanField(
|
||||||
|
label=_("I confirm that I have read the caution and that I am aware of the risks involved."),
|
||||||
|
required=False,
|
||||||
|
),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
import os
|
import os
|
||||||
import shutil
|
import shutil
|
||||||
import subprocess
|
import subprocess
|
||||||
from datetime import date, timedelta
|
from datetime import date
|
||||||
from tempfile import mkdtemp
|
from tempfile import mkdtemp
|
||||||
|
|
||||||
from django.conf import settings
|
from django.conf import settings
|
||||||
@ -21,7 +21,7 @@ from django.shortcuts import redirect
|
|||||||
from django.template.loader import render_to_string
|
from django.template.loader import render_to_string
|
||||||
from django.urls import reverse_lazy
|
from django.urls import reverse_lazy
|
||||||
from django.views import View
|
from django.views import View
|
||||||
from django.views.generic import DetailView, UpdateView, RedirectView, TemplateView, CreateView
|
from django.views.generic import DetailView, UpdateView, RedirectView, TemplateView
|
||||||
from django.utils.translation import gettext_lazy as _
|
from django.utils.translation import gettext_lazy as _
|
||||||
from django.views.generic.edit import BaseFormView, DeleteView
|
from django.views.generic.edit import BaseFormView, DeleteView
|
||||||
from django_tables2 import SingleTableView, MultiTableMixin
|
from django_tables2 import SingleTableView, MultiTableMixin
|
||||||
@ -39,7 +39,6 @@ from .forms import WEIForm, WEIRegistrationForm, BusForm, BusTeamForm, WEIMember
|
|||||||
WEIMembershipForm, CurrentSurvey
|
WEIMembershipForm, CurrentSurvey
|
||||||
from .tables import BusRepartitionTable, BusTable, BusTeamTable, WEITable, WEIRegistrationTable, \
|
from .tables import BusRepartitionTable, BusTable, BusTeamTable, WEITable, WEIRegistrationTable, \
|
||||||
WEIRegistration1ATable, WEIMembershipTable
|
WEIRegistration1ATable, WEIMembershipTable
|
||||||
from .forms.surveys import CurrentSurvey
|
|
||||||
|
|
||||||
|
|
||||||
class CurrentWEIDetailView(LoginRequiredMixin, RedirectView):
|
class CurrentWEIDetailView(LoginRequiredMixin, RedirectView):
|
||||||
@ -449,9 +448,6 @@ class BusTeamCreateView(ProtectQuerysetMixin, ProtectedCreateView):
|
|||||||
return names
|
return names
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
class BusTeamUpdateView(ProtectQuerysetMixin, LoginRequiredMixin, UpdateView):
|
class BusTeamUpdateView(ProtectQuerysetMixin, LoginRequiredMixin, UpdateView):
|
||||||
"""
|
"""
|
||||||
Update Bus team
|
Update Bus team
|
||||||
@ -488,9 +484,6 @@ class BusTeamUpdateView(ProtectQuerysetMixin, LoginRequiredMixin, UpdateView):
|
|||||||
return names
|
return names
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
class BusTeamManageView(ProtectQuerysetMixin, LoginRequiredMixin, DetailView):
|
class BusTeamManageView(ProtectQuerysetMixin, LoginRequiredMixin, DetailView):
|
||||||
"""
|
"""
|
||||||
Manage Bus team
|
Manage Bus team
|
||||||
|
Loading…
x
Reference in New Issue
Block a user