diff --git a/apps/registration/forms.py b/apps/registration/forms.py
index 5f62398..c526fd4 100644
--- a/apps/registration/forms.py
+++ b/apps/registration/forms.py
@@ -100,7 +100,7 @@ class StudentRegistrationForm(forms.ModelForm):
"""
class Meta:
model = StudentRegistration
- fields = ('team', 'student_class', 'birth_date', 'gender', 'address', 'phone_number',
+ fields = ('team', 'student_class', 'birth_date', 'gender', 'address', 'phone_number', 'health_issues',
'school', 'responsible_name', 'responsible_phone', 'responsible_email',
'give_contact_to_animath', 'email_confirmed',)
@@ -177,7 +177,7 @@ class CoachRegistrationForm(forms.ModelForm):
"""
class Meta:
model = CoachRegistration
- fields = ('team', 'birth_date', 'gender', 'address', 'phone_number', 'professional_activity',
+ fields = ('team', 'birth_date', 'gender', 'address', 'phone_number', 'health_issues', 'professional_activity',
'give_contact_to_animath', 'email_confirmed',)
diff --git a/apps/registration/migrations/0002_participantregistration_health_issues.py b/apps/registration/migrations/0002_participantregistration_health_issues.py
new file mode 100644
index 0000000..e50b992
--- /dev/null
+++ b/apps/registration/migrations/0002_participantregistration_health_issues.py
@@ -0,0 +1,18 @@
+# Generated by Django 3.0.11 on 2021-01-23 20:52
+
+from django.db import migrations, models
+
+
+class Migration(migrations.Migration):
+
+ dependencies = [
+ ('registration', '0001_initial'),
+ ]
+
+ operations = [
+ migrations.AddField(
+ model_name='participantregistration',
+ name='health_issues',
+ field=models.TextField(blank=True, help_text='You can indicate here your allergies or anything that is important to know for organizers', verbose_name='health issues'),
+ ),
+ ]
diff --git a/apps/registration/models.py b/apps/registration/models.py
index 3a603f8..91da4b6 100644
--- a/apps/registration/models.py
+++ b/apps/registration/models.py
@@ -150,6 +150,12 @@ class ParticipantRegistration(Registration):
blank=True,
)
+ health_issues = models.TextField(
+ verbose_name=_("health issues"),
+ blank=True,
+ help_text=_("You can indicate here your allergies or anything that is important to know for organizers"),
+ )
+
photo_authorization = models.FileField(
verbose_name=_("photo authorization"),
upload_to=get_random_photo_filename,
diff --git a/apps/registration/templates/registration/user_detail.html b/apps/registration/templates/registration/user_detail.html
index c0d6320..ff3c6ad 100644
--- a/apps/registration/templates/registration/user_detail.html
+++ b/apps/registration/templates/registration/user_detail.html
@@ -51,6 +51,9 @@
{% trans "Phone number:" %}
{{ user_object.registration.phone_number }}
+ {% trans "Health issues:" %}
+ {{ user_object.registration.health_issues|default:any }}
+
{% trans "Photo authorization:" %}
{% if user_object.registration.photo_authorization %}
diff --git a/locale/fr/LC_MESSAGES/django.po b/locale/fr/LC_MESSAGES/django.po
index 4400d06..09fb9bf 100644
--- a/locale/fr/LC_MESSAGES/django.po
+++ b/locale/fr/LC_MESSAGES/django.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: TFJM\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2021-01-23 21:33+0100\n"
+"POT-Creation-Date: 2021-01-23 21:55+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Yohann D'ANELLO \n"
"Language-Team: LANGUAGE \n"
@@ -100,7 +100,7 @@ msgid "Changelog of type \"{action}\" for model {model} at {timestamp}"
msgstr "Changelog de type \"{action}\" pour le modèle {model} le {timestamp}"
#: apps/participation/admin.py:19 apps/participation/models.py:314
-#: apps/participation/tables.py:44 apps/registration/models.py:352
+#: apps/participation/tables.py:44 apps/registration/models.py:358
msgid "valid"
msgstr "valide"
@@ -528,9 +528,9 @@ msgstr "Rejoindre"
#: apps/participation/templates/participation/update_team.html:12
#: apps/registration/templates/registration/payment_form.html:49
#: apps/registration/templates/registration/update_user.html:16
-#: apps/registration/templates/registration/user_detail.html:150
-#: apps/registration/templates/registration/user_detail.html:159
-#: apps/registration/templates/registration/user_detail.html:187
+#: apps/registration/templates/registration/user_detail.html:153
+#: apps/registration/templates/registration/user_detail.html:162
+#: apps/registration/templates/registration/user_detail.html:190
msgid "Update"
msgstr "Modifier"
@@ -586,10 +586,10 @@ msgstr "Envoyer une solution"
#: apps/registration/templates/registration/upload_health_sheet.html:17
#: apps/registration/templates/registration/upload_parental_authorization.html:17
#: apps/registration/templates/registration/upload_photo_authorization.html:18
-#: apps/registration/templates/registration/user_detail.html:165
-#: apps/registration/templates/registration/user_detail.html:170
-#: apps/registration/templates/registration/user_detail.html:175
-#: apps/registration/templates/registration/user_detail.html:180
+#: apps/registration/templates/registration/user_detail.html:168
+#: apps/registration/templates/registration/user_detail.html:173
+#: apps/registration/templates/registration/user_detail.html:178
+#: apps/registration/templates/registration/user_detail.html:183
msgid "Upload"
msgstr "Téléverser"
@@ -780,16 +780,16 @@ msgstr "Lettre de motivation :"
#: apps/participation/templates/participation/team_detail.html:94
#: apps/registration/templates/registration/upload_health_sheet.html:12
#: apps/registration/templates/registration/upload_parental_authorization.html:12
-#: apps/registration/templates/registration/user_detail.html:57
-#: apps/registration/templates/registration/user_detail.html:70
-#: apps/registration/templates/registration/user_detail.html:80
+#: apps/registration/templates/registration/user_detail.html:60
+#: apps/registration/templates/registration/user_detail.html:73
+#: apps/registration/templates/registration/user_detail.html:83
msgid "Download"
msgstr "Télécharger"
#: apps/participation/templates/participation/team_detail.html:99
-#: apps/registration/templates/registration/user_detail.html:60
-#: apps/registration/templates/registration/user_detail.html:73
-#: apps/registration/templates/registration/user_detail.html:83
+#: apps/registration/templates/registration/user_detail.html:63
+#: apps/registration/templates/registration/user_detail.html:76
+#: apps/registration/templates/registration/user_detail.html:86
msgid "Replace"
msgstr "Remplacer"
@@ -1087,7 +1087,7 @@ msgstr "rôle"
msgid "participant"
msgstr "participant"
-#: apps/registration/forms.py:24 apps/registration/models.py:253
+#: apps/registration/forms.py:24 apps/registration/models.py:259
msgid "coach"
msgstr "encadrant"
@@ -1095,11 +1095,11 @@ msgstr "encadrant"
msgid "This email address is already used."
msgstr "Cette adresse e-mail est déjà utilisée."
-#: apps/registration/forms.py:55 apps/registration/models.py:279
+#: apps/registration/forms.py:55 apps/registration/models.py:285
msgid "volunteer"
msgstr "bénévole"
-#: apps/registration/forms.py:56 apps/registration/models.py:298
+#: apps/registration/forms.py:56 apps/registration/models.py:304
msgid "admin"
msgstr "admin"
@@ -1124,7 +1124,7 @@ msgstr "email confirmé"
msgid "Activate your TFJM² account"
msgstr "Activez votre compte du TFJM²"
-#: apps/registration/models.py:99 apps/registration/models.py:319
+#: apps/registration/models.py:99 apps/registration/models.py:325
msgid "registration"
msgstr "inscription"
@@ -1161,131 +1161,143 @@ msgid "phone number"
msgstr "numéro de téléphone"
#: apps/registration/models.py:154
+msgid "health issues"
+msgstr "problèmes de santé"
+
+#: apps/registration/models.py:156
+msgid ""
+"You can indicate here your allergies or anything that is important to know "
+"for organizers"
+msgstr ""
+"Vous pouvez indiquer ici vos allergies ou n'importe quoi qui peut être bon à "
+"savoir pour les organisateurs"
+
+#: apps/registration/models.py:160
msgid "photo authorization"
msgstr "autorisation de droit à l'image"
-#: apps/registration/models.py:186
+#: apps/registration/models.py:192
msgid "12th grade"
msgstr "Terminale"
-#: apps/registration/models.py:187
+#: apps/registration/models.py:193
msgid "11th grade"
msgstr "Première"
-#: apps/registration/models.py:188
+#: apps/registration/models.py:194
msgid "10th grade or lower"
msgstr "Seconde ou inférieur"
-#: apps/registration/models.py:190
+#: apps/registration/models.py:196
msgid "student class"
msgstr "classe"
-#: apps/registration/models.py:195
+#: apps/registration/models.py:201
msgid "school"
msgstr "école"
-#: apps/registration/models.py:200
+#: apps/registration/models.py:206
msgid "responsible name"
msgstr "nom du responsable légal"
-#: apps/registration/models.py:205
+#: apps/registration/models.py:211
msgid "responsible phone number"
msgstr "numéro de téléphone du responsable légal"
-#: apps/registration/models.py:210
+#: apps/registration/models.py:216
msgid "responsible email address"
msgstr "adresse e-mail du responsable légal"
-#: apps/registration/models.py:215
+#: apps/registration/models.py:221
msgid "parental authorization"
msgstr "autorisation parentale"
-#: apps/registration/models.py:222
+#: apps/registration/models.py:228
msgid "health sheet"
msgstr "fiche sanitaire"
-#: apps/registration/models.py:230
+#: apps/registration/models.py:236
msgid "student"
msgstr "étudiant"
-#: apps/registration/models.py:238
+#: apps/registration/models.py:244
msgid "student registration"
msgstr "inscription d'élève"
-#: apps/registration/models.py:239
+#: apps/registration/models.py:245
msgid "student registrations"
msgstr "inscriptions d'élève"
-#: apps/registration/models.py:248 apps/registration/models.py:270
+#: apps/registration/models.py:254 apps/registration/models.py:276
msgid "professional activity"
msgstr "activité professionnelle"
-#: apps/registration/models.py:261
+#: apps/registration/models.py:267
msgid "coach registration"
msgstr "inscription d'encadrant"
-#: apps/registration/models.py:262
+#: apps/registration/models.py:268
msgid "coach registrations"
msgstr "inscriptions d'encadrants"
-#: apps/registration/models.py:293
+#: apps/registration/models.py:299
msgid "role of the administrator"
msgstr "rôle de l'administrateur"
-#: apps/registration/models.py:306
+#: apps/registration/models.py:312
msgid "admin registration"
msgstr "inscription d'administrateur"
-#: apps/registration/models.py:307
+#: apps/registration/models.py:313
msgid "admin registrations"
msgstr "inscriptions d'administrateur"
-#: apps/registration/models.py:323
+#: apps/registration/models.py:329
msgid "type"
msgstr "type"
-#: apps/registration/models.py:326
+#: apps/registration/models.py:332
msgid "No payment"
msgstr "Pas de paiement"
-#: apps/registration/models.py:328
+#: apps/registration/models.py:334
msgid "Scholarship"
msgstr "Notification de bourse"
-#: apps/registration/models.py:329
+#: apps/registration/models.py:335
msgid "Bank transfer"
msgstr "Virement bancaire"
-#: apps/registration/models.py:330
+#: apps/registration/models.py:336
msgid "The tournament is free"
msgstr "Le tournoi est gratuit"
-#: apps/registration/models.py:337
+#: apps/registration/models.py:343
msgid "scholarship file"
msgstr "Notification de bourse"
-#: apps/registration/models.py:338
+#: apps/registration/models.py:344
msgid "only if you have a scholarship."
msgstr "Nécessaire seulement si vous déclarez être boursier."
-#: apps/registration/models.py:345
+#: apps/registration/models.py:351
msgid "additional information"
msgstr "informations additionnelles"
-#: apps/registration/models.py:346
+#: apps/registration/models.py:352
msgid "To help us to find your payment."
msgstr "Pour nous aider à retrouver votre paiement, si nécessaire."
-#: apps/registration/models.py:361
+#: apps/registration/models.py:367
#, python-brace-format
msgid "Payment of {registration}"
msgstr "Paiement de {registration}"
-#: apps/registration/models.py:364
+#: apps/registration/models.py:370
msgid "payment"
msgstr "paiement"
-#: apps/registration/models.py:365
+#: apps/registration/models.py:371
msgid "payments"
msgstr "paiements"
@@ -1572,91 +1584,95 @@ msgid "Phone number:"
msgstr "Numéro de téléphone :"
#: apps/registration/templates/registration/user_detail.html:54
+msgid "Health issues:"
+msgstr "Problèmes de santé :"
+
+#: apps/registration/templates/registration/user_detail.html:57
msgid "Photo authorization:"
msgstr "Autorisation de droit à l'image"
-#: apps/registration/templates/registration/user_detail.html:67
+#: apps/registration/templates/registration/user_detail.html:70
msgid "Health sheet:"
msgstr "Fiche sanitaire :"
-#: apps/registration/templates/registration/user_detail.html:77
+#: apps/registration/templates/registration/user_detail.html:80
msgid "Parental authorization:"
msgstr "Autorisation parentale :"
-#: apps/registration/templates/registration/user_detail.html:88
+#: apps/registration/templates/registration/user_detail.html:91
msgid "Student class:"
msgstr "Classe :"
-#: apps/registration/templates/registration/user_detail.html:91
+#: apps/registration/templates/registration/user_detail.html:94
msgid "School:"
msgstr "École :"
-#: apps/registration/templates/registration/user_detail.html:94
+#: apps/registration/templates/registration/user_detail.html:97
msgid "Responsible name:"
msgstr "Nom du responsable légal :"
-#: apps/registration/templates/registration/user_detail.html:97
+#: apps/registration/templates/registration/user_detail.html:100
msgid "Responsible phone number:"
msgstr "Numéro de téléphone du responsable légal :"
-#: apps/registration/templates/registration/user_detail.html:100
+#: apps/registration/templates/registration/user_detail.html:103
msgid "Responsible email address:"
msgstr "Adresse e-mail du responsable légal :"
-#: apps/registration/templates/registration/user_detail.html:105
+#: apps/registration/templates/registration/user_detail.html:108
msgid "Role:"
msgstr "Rôle :"
-#: apps/registration/templates/registration/user_detail.html:108
+#: apps/registration/templates/registration/user_detail.html:111
msgid "Profesional activity:"
msgstr "Activité professionnelle :"
-#: apps/registration/templates/registration/user_detail.html:112
+#: apps/registration/templates/registration/user_detail.html:115
msgid "Grant Animath to contact me in the future about other actions:"
msgstr "Autorise Animath à recontacter à propos d'autres actions :"
-#: apps/registration/templates/registration/user_detail.html:120
+#: apps/registration/templates/registration/user_detail.html:123
msgid "Payment information:"
msgstr "Informations de paiement :"
-#: apps/registration/templates/registration/user_detail.html:122
+#: apps/registration/templates/registration/user_detail.html:125
msgid "yes,no,pending"
msgstr "oui,non,en attente"
-#: apps/registration/templates/registration/user_detail.html:126
#: apps/registration/templates/registration/user_detail.html:129
+#: apps/registration/templates/registration/user_detail.html:132
msgid "valid:"
msgstr "valide :"
-#: apps/registration/templates/registration/user_detail.html:133
-#: apps/registration/templates/registration/user_detail.html:186
+#: apps/registration/templates/registration/user_detail.html:136
+#: apps/registration/templates/registration/user_detail.html:189
msgid "Update payment"
msgstr "Modifier le paiement"
-#: apps/registration/templates/registration/user_detail.html:139
+#: apps/registration/templates/registration/user_detail.html:142
msgid "Download scholarship attestation"
msgstr "Télécharger l'attestation de bourse"
-#: apps/registration/templates/registration/user_detail.html:152
+#: apps/registration/templates/registration/user_detail.html:155
msgid "Impersonate"
msgstr "Impersonifier"
-#: apps/registration/templates/registration/user_detail.html:158
+#: apps/registration/templates/registration/user_detail.html:161
msgid "Update user"
msgstr "Modifier l'utilisateur"
-#: apps/registration/templates/registration/user_detail.html:164
+#: apps/registration/templates/registration/user_detail.html:167
#: apps/registration/views.py:313
msgid "Upload photo authorization"
msgstr "Téléverser l'autorisation de droit à l'image"
-#: apps/registration/templates/registration/user_detail.html:169
+#: apps/registration/templates/registration/user_detail.html:172
#: apps/registration/views.py:334
msgid "Upload health sheet"
msgstr "Téléverser la fiche sanitaire"
-#: apps/registration/templates/registration/user_detail.html:174
-#: apps/registration/templates/registration/user_detail.html:179
+#: apps/registration/templates/registration/user_detail.html:177
+#: apps/registration/templates/registration/user_detail.html:182
#: apps/registration/views.py:355
msgid "Upload parental authorization"
msgstr "Téléverser l'autorisation parentale"
@@ -1879,9 +1895,3 @@ msgstr "Résultats"
#: tfjm/templates/search/search.html:25
msgid "No results found."
msgstr "Aucun résultat."
-
-#~ msgid "You are not an administrator."
-#~ msgstr "Vous n'êtes pas administrateur."
-
-#~ msgid "The code of the form xxx-xxx-xxx at the end of the BBB link."
-#~ msgstr "Le code de la forme xxx-xxx-xxx à la fin du lien BBB."