From 2a2786ba6db51dc574bcd60810545febd7e8db79 Mon Sep 17 00:00:00 2001 From: Emmy D'Anello Date: Sat, 24 Feb 2024 22:55:34 +0100 Subject: [PATCH] Add payment information after payment Signed-off-by: Emmy D'Anello --- locale/fr/LC_MESSAGES/django.po | 408 +++++++++++------- .../templates/registration/payment_form.html | 83 +++- registration/views.py | 9 +- 3 files changed, 323 insertions(+), 177 deletions(-) diff --git a/locale/fr/LC_MESSAGES/django.po b/locale/fr/LC_MESSAGES/django.po index 90fe9a2..45b1e64 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: 2024-02-23 22:57+0100\n" +"POT-Creation-Date: 2024-02-24 22:48+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: Emmy D'Anello \n" "Language-Team: LANGUAGE \n" @@ -31,8 +31,8 @@ msgstr "équipes" #: participation/admin.py:79 participation/admin.py:140 #: participation/admin.py:171 participation/models.py:419 #: participation/models.py:443 participation/models.py:513 -#: registration/models.py:619 -#: registration/templates/registration/payment_form.html:51 +#: registration/models.py:618 +#: registration/templates/registration/payment_form.html:53 msgid "tournament" msgstr "tournoi" @@ -333,9 +333,9 @@ msgstr "Continuer le tirage" #: draw/templates/draw/tournament_content.html:216 participation/admin.py:167 #: participation/models.py:249 participation/models.py:434 -#: registration/models.py:157 registration/models.py:610 +#: registration/models.py:156 registration/models.py:609 #: registration/tables.py:39 -#: registration/templates/registration/payment_form.html:50 +#: registration/templates/registration/payment_form.html:52 msgid "team" msgstr "équipe" @@ -377,8 +377,8 @@ msgstr "Êtes-vous sûr·e de vouloir annuler le tirage au sort ?" msgid "Close" msgstr "Fermer" -#: draw/views.py:31 participation/views.py:154 participation/views.py:447 -#: participation/views.py:478 +#: draw/views.py:31 participation/views.py:154 participation/views.py:440 +#: participation/views.py:471 msgid "You are not in a team." msgstr "Vous n'êtes pas dans une équipe." @@ -386,7 +386,7 @@ msgstr "Vous n'êtes pas dans une équipe." msgid "Logs" msgstr "Logs" -#: logs/models.py:22 registration/models.py:34 +#: logs/models.py:22 registration/models.py:33 msgid "user" msgstr "utilisateur" @@ -493,14 +493,14 @@ msgstr "Aucune équipe n'a été trouvée avec ce code d'accès." #: participation/forms.py:86 participation/forms.py:351 #: registration/forms.py:122 registration/forms.py:144 #: registration/forms.py:166 registration/forms.py:188 -#: registration/forms.py:234 registration/forms.py:267 +#: registration/forms.py:237 registration/forms.py:270 msgid "The uploaded file size must be under 2 Mo." msgstr "Le fichier envoyé doit peser moins de 2 Mo." #: participation/forms.py:88 registration/forms.py:124 #: registration/forms.py:146 registration/forms.py:168 -#: registration/forms.py:190 registration/forms.py:236 -#: registration/forms.py:269 +#: registration/forms.py:190 registration/forms.py:239 +#: registration/forms.py:272 msgid "The uploaded file must be a PDF, PNG of JPEG file." msgstr "Le fichier envoyé doit être au format PDF, PNG ou JPEG." @@ -720,7 +720,7 @@ msgstr "" "L'équipe {trigram} n'a pas encore été validée par les organisateurices. " "Merci de patienter." -#: participation/models.py:193 registration/models.py:493 +#: participation/models.py:193 registration/models.py:492 msgid "Pending validation" msgstr "Validation en attente" @@ -1100,7 +1100,7 @@ msgstr "Rejoindre" #: participation/templates/participation/tournament_form.html:12 #: participation/templates/participation/update_team.html:12 #: registration/tables.py:46 -#: registration/templates/registration/payment_form.html:207 +#: registration/templates/registration/payment_form.html:210 #: registration/templates/registration/update_user.html:16 #: registration/templates/registration/user_detail.html:186 msgid "Update" @@ -1434,6 +1434,8 @@ msgid "Motivation letter:" msgstr "Lettre de motivation :" #: participation/templates/participation/team_detail.html:107 +#: registration/templates/registration/payment_form.html:247 +#: registration/templates/registration/payment_form.html:269 #: registration/templates/registration/upload_health_sheet.html:12 #: registration/templates/registration/upload_parental_authorization.html:12 #: registration/templates/registration/user_detail.html:69 @@ -1460,13 +1462,13 @@ msgid "Payment of" msgstr "Paiement de" #: participation/templates/participation/team_detail.html:132 -#: registration/models.py:540 +#: registration/models.py:539 msgid "grouped" msgstr "groupé" #: participation/templates/participation/team_detail.html:140 #: registration/templates/registration/user_detail.html:163 -#: registration/views.py:461 +#: registration/views.py:460 msgid "Update payment" msgstr "Mettre à jour le paiement" @@ -1525,7 +1527,7 @@ msgid "Invalidate" msgstr "Invalider" #: participation/templates/participation/team_detail.html:209 -#: participation/views.py:332 +#: participation/views.py:325 msgid "Upload motivation letter" msgstr "Envoyer la lettre de motivation" @@ -1534,7 +1536,7 @@ msgid "Update team" msgstr "Modifier l'équipe" #: participation/templates/participation/team_detail.html:219 -#: participation/views.py:441 +#: participation/views.py:434 msgid "Leave team" msgstr "Quitter l'équipe" @@ -1679,7 +1681,7 @@ msgstr "Vous êtes déjà dans une équipe." msgid "Join team" msgstr "Rejoindre une équipe" -#: participation/views.py:155 participation/views.py:479 +#: participation/views.py:155 participation/views.py:472 msgid "You don't participate, so you don't have any team." msgstr "Vous ne participez pas, vous n'avez donc pas d'équipe." @@ -1715,100 +1717,100 @@ msgstr "Vous n'êtes pas un⋅e organisateur⋅rice du tournoi." msgid "This team has no pending validation." msgstr "L'équipe n'a pas de validation en attente." -#: participation/views.py:275 +#: participation/views.py:268 msgid "You must specify if you validate the registration or not." msgstr "Vous devez spécifier si vous validez l'inscription ou non." -#: participation/views.py:310 +#: participation/views.py:303 #, python-brace-format msgid "Update team {trigram}" msgstr "Mise à jour de l'équipe {trigram}" -#: participation/views.py:371 participation/views.py:427 +#: participation/views.py:364 participation/views.py:420 #, python-brace-format msgid "Motivation letter of {team}.{ext}" msgstr "Lettre de motivation de {team}.{ext}" -#: participation/views.py:402 +#: participation/views.py:395 #, python-brace-format msgid "Photo authorization of {participant}.{ext}" msgstr "Autorisation de droit à l'image de {participant}.{ext}" -#: participation/views.py:408 +#: participation/views.py:401 #, python-brace-format msgid "Parental authorization of {participant}.{ext}" msgstr "Autorisation parentale de {participant}.{ext}" -#: participation/views.py:415 +#: participation/views.py:408 #, python-brace-format msgid "Health sheet of {participant}.{ext}" msgstr "Fiche sanitaire de {participant}.{ext}" -#: participation/views.py:421 +#: participation/views.py:414 #, python-brace-format msgid "Vaccine sheet of {participant}.{ext}" msgstr "Carnet de vaccination de {participant}.{ext}" -#: participation/views.py:431 +#: participation/views.py:424 #, python-brace-format msgid "Photo authorizations of team {trigram}.zip" msgstr "Autorisations de droit à l'image de l'équipe {trigram}.zip" -#: participation/views.py:449 +#: participation/views.py:442 msgid "The team is already validated or the validation is pending." msgstr "La validation de l'équipe est déjà faite ou en cours." -#: participation/views.py:493 +#: participation/views.py:486 msgid "The team is not validated yet." msgstr "L'équipe n'est pas encore validée." -#: participation/views.py:507 +#: participation/views.py:500 #, python-brace-format msgid "Participation of team {trigram}" msgstr "Participation de l'équipe {trigram}" -#: participation/views.py:588 +#: participation/views.py:581 #, python-brace-format msgid "Payments of {tournament}" msgstr "Paiements de {tournament}" -#: participation/views.py:668 +#: participation/views.py:661 msgid "You can't upload a solution after the deadline." msgstr "Vous ne pouvez pas envoyer de solution après la date limite." -#: participation/views.py:776 +#: participation/views.py:769 #, python-brace-format msgid "Solutions for pool {pool} of tournament {tournament}.zip" msgstr "Solutions pour la poule {pool} du tournoi {tournament}.zip" -#: participation/views.py:777 +#: participation/views.py:770 #, python-brace-format msgid "Syntheses for pool {pool} of tournament {tournament}.zip" msgstr "Notes de synthèses pour la poule {pool} du tournoi {tournament}.zip" -#: participation/views.py:795 +#: participation/views.py:788 #, python-brace-format msgid "Jurys of {pool}" msgstr "Juré⋅es de la {pool}" -#: participation/views.py:822 +#: participation/views.py:815 msgid "New TFJM² jury account" msgstr "Nouveau compte de juré⋅e pour le TFJM²" -#: participation/views.py:835 +#: participation/views.py:828 #, python-brace-format msgid "The jury {name} has been successfully added!" msgstr "{name} a été ajouté⋅e avec succès en tant que juré⋅e !" -#: participation/views.py:872 +#: participation/views.py:865 msgid "The following user is not registered as a jury:" msgstr "L'utilisateur⋅rice suivant n'est pas inscrit⋅e en tant que juré⋅e :" -#: participation/views.py:886 +#: participation/views.py:879 msgid "Notes were successfully uploaded." msgstr "Les notes ont bien été envoyées." -#: participation/views.py:1550 +#: participation/views.py:1543 msgid "You can't upload a synthesis after the deadline." msgstr "Vous ne pouvez pas envoyer de note de synthèse après la date limite." @@ -1847,7 +1849,7 @@ msgstr "rôle" msgid "participant" msgstr "participant⋅e" -#: registration/forms.py:25 registration/models.py:427 +#: registration/forms.py:25 registration/models.py:426 msgid "coach" msgstr "encadrant⋅e" @@ -1855,24 +1857,24 @@ msgstr "encadrant⋅e" msgid "Pending" msgstr "En attente" -#: registration/forms.py:244 registration/forms.py:277 +#: registration/forms.py:247 registration/forms.py:280 msgid "You must upload your receipt." msgstr "Vous devez envoyer votre justificatif." -#: registration/models.py:39 +#: registration/models.py:38 msgid "Grant Animath to contact me in the future about other actions" msgstr "" "Autoriser Animath à me recontacter à l'avenir à propos d'autres actions" -#: registration/models.py:44 +#: registration/models.py:43 msgid "email confirmed" msgstr "email confirmé" -#: registration/models.py:52 +#: registration/models.py:51 msgid "Activate your TFJM² account" msgstr "Activez votre compte du TFJM²" -#: registration/models.py:109 +#: registration/models.py:108 #, python-brace-format msgid "" "Your email address is not validated. Please click on the link you received " @@ -1883,52 +1885,52 @@ msgstr "" "avez reçu par mail. Vous pouvez renvoyer un mail en cliquant sur ce lien." -#: registration/models.py:129 +#: registration/models.py:128 msgid "registration" msgstr "inscription" -#: registration/models.py:130 registration/models.py:536 +#: registration/models.py:129 registration/models.py:535 msgid "registrations" msgstr "inscriptions" -#: registration/models.py:162 +#: registration/models.py:161 msgid "gender" msgstr "genre" -#: registration/models.py:164 +#: registration/models.py:163 msgid "Female" msgstr "Femme" -#: registration/models.py:165 +#: registration/models.py:164 msgid "Male" msgstr "Homme" -#: registration/models.py:166 -#: registration/templates/registration/payment_form.html:87 +#: registration/models.py:165 +#: registration/templates/registration/payment_form.html:89 msgid "Other" msgstr "Autre" -#: registration/models.py:173 +#: registration/models.py:172 msgid "address" msgstr "adresse" -#: registration/models.py:177 +#: registration/models.py:176 msgid "zip code" msgstr "code postal" -#: registration/models.py:183 +#: registration/models.py:182 msgid "city" msgstr "ville" -#: registration/models.py:187 +#: registration/models.py:186 msgid "phone number" msgstr "numéro de téléphone" -#: registration/models.py:192 +#: registration/models.py:191 msgid "health issues" msgstr "problèmes de santé" -#: registration/models.py:194 +#: registration/models.py:193 msgid "" "You can indicate here your allergies or anything that is important to know " "for organizers." @@ -1936,11 +1938,11 @@ msgstr "" "Vous pouvez indiquer ici vos allergies ou n'importe quoi qui peut être bon à " "savoir pour les organisateur⋅rices." -#: registration/models.py:198 +#: registration/models.py:197 msgid "housing constraints" msgstr "contraintes de logement" -#: registration/models.py:200 +#: registration/models.py:199 msgid "" "You can fill in something here if you have any housing constraints, e.g. " "medical problems, scheduling issues, gender issues, or anything else you " @@ -1953,11 +1955,11 @@ msgstr "" "organisateur⋅rices. Laissez vide si vous n'avez rien de spécifique à " "déclarer." -#: registration/models.py:207 +#: registration/models.py:206 msgid "photo authorization" msgstr "autorisation de droit à l'image" -#: registration/models.py:236 +#: registration/models.py:235 #, python-brace-format msgid "" "You are not in a team. You can create one or ou rejoindre une équipe existante pour " "participer." -#: registration/models.py:242 +#: registration/models.py:241 msgid "No team" msgstr "Pas d'équipe" -#: registration/models.py:250 +#: registration/models.py:249 #, python-brace-format msgid "" "You have not uploaded your photo authorization. You can do it by clicking on " @@ -1980,71 +1982,71 @@ msgstr "" "Vous n'avez pas envoyé votre autorisation de droit à l'image. Vous pouvez le " "faire en cliquant sur ce lien." -#: registration/models.py:255 +#: registration/models.py:254 msgid "Photo authorization" msgstr "Autorisation de droit à l'image" -#: registration/models.py:266 +#: registration/models.py:265 msgid "participant registration" msgstr "inscription de participant⋅e" -#: registration/models.py:267 +#: registration/models.py:266 msgid "participant registrations" msgstr "inscriptions de participant⋅es" -#: registration/models.py:276 +#: registration/models.py:275 msgid "birth date" msgstr "date de naissance" -#: registration/models.py:282 +#: registration/models.py:281 msgid "12th grade" msgstr "Terminale" -#: registration/models.py:283 +#: registration/models.py:282 msgid "11th grade" msgstr "Première" -#: registration/models.py:284 +#: registration/models.py:283 msgid "10th grade or lower" msgstr "Seconde ou inférieur" -#: registration/models.py:286 +#: registration/models.py:285 msgid "student class" msgstr "classe" -#: registration/models.py:291 +#: registration/models.py:290 msgid "school" msgstr "école" -#: registration/models.py:296 +#: registration/models.py:295 msgid "responsible name" msgstr "nom d'un⋅e responsable légal⋅e" -#: registration/models.py:301 +#: registration/models.py:300 msgid "responsible phone number" msgstr "numéro de téléphone d'un⋅e responsable légal⋅e" -#: registration/models.py:306 +#: registration/models.py:305 msgid "responsible email address" msgstr "adresse e-mail d'un⋅e responsable légal⋅e" -#: registration/models.py:311 +#: registration/models.py:310 msgid "parental authorization" msgstr "autorisation parentale" -#: registration/models.py:318 +#: registration/models.py:317 msgid "health sheet" msgstr "fiche sanitaire" -#: registration/models.py:325 +#: registration/models.py:324 msgid "vaccine sheet" msgstr "carnet de vaccination" -#: registration/models.py:333 +#: registration/models.py:332 msgid "student" msgstr "élève" -#: registration/models.py:344 +#: registration/models.py:343 #, python-brace-format msgid "" "You have not uploaded your parental authorization. You can do it by clicking " @@ -2053,11 +2055,11 @@ msgstr "" "Vous n'avez pas envoyé votre autorisation parentale. Vous pouvez le faire en " "cliquant sur ce lien." -#: registration/models.py:349 +#: registration/models.py:348 msgid "Parental authorization" msgstr "Autorisation parentale" -#: registration/models.py:355 +#: registration/models.py:354 #, python-brace-format msgid "" "You have not uploaded your health sheet. You can do it by clicking on ce lien." -#: registration/models.py:360 +#: registration/models.py:359 msgid "Health sheet" msgstr "Fiche sanitaire" -#: registration/models.py:366 +#: registration/models.py:365 #, python-brace-format msgid "" "You have not uploaded your vaccine sheet. You can do it by clicking on ce lien." -#: registration/models.py:371 +#: registration/models.py:370 msgid "Vaccine sheet" msgstr "Carnet de vaccination" -#: registration/models.py:380 +#: registration/models.py:379 #, python-brace-format msgid "" "You have to pay {amount} € for your registration, or send a scholarship " @@ -2094,27 +2096,27 @@ msgstr "" "notification de bourse ou un justificatif de paiement. Vous pouvez le faire " "sur la page de paiement." -#: registration/models.py:386 registration/models.py:395 +#: registration/models.py:385 registration/models.py:394 msgid "Payment" msgstr "Paiement" -#: registration/models.py:392 +#: registration/models.py:391 msgid "Your payment is under approval." msgstr "Votre paiement est en cours de validation." -#: registration/models.py:404 +#: registration/models.py:403 msgid "student registration" msgstr "inscription d'élève" -#: registration/models.py:405 +#: registration/models.py:404 msgid "student registrations" msgstr "inscriptions d'élève" -#: registration/models.py:416 +#: registration/models.py:415 msgid "most recent degree in mathematics, computer science or physics" msgstr "Dernier diplôme obtenu en mathématiques, informatique ou physique" -#: registration/models.py:417 +#: registration/models.py:416 msgid "" "Your most recent degree in maths, computer science or physics, or your last " "entrance exam (CAPES, Agrégation,…)" @@ -2122,23 +2124,23 @@ msgstr "" "Votre dernier diplôme en mathématiques, informatique ou physique, ou votre " "dernier concours obtenu (CAPES, Agrégation, …)" -#: registration/models.py:422 registration/models.py:444 +#: registration/models.py:421 registration/models.py:443 msgid "professional activity" msgstr "activité professionnelle" -#: registration/models.py:435 +#: registration/models.py:434 msgid "coach registration" msgstr "inscription d'encadrant⋅e" -#: registration/models.py:436 +#: registration/models.py:435 msgid "coach registrations" msgstr "inscriptions d'encadrant⋅es" -#: registration/models.py:448 +#: registration/models.py:447 msgid "administrator" msgstr "administrateur⋅rice" -#: registration/models.py:449 +#: registration/models.py:448 msgid "" "An administrator has all rights. Please don't give this right to all juries " "and volunteers." @@ -2146,15 +2148,15 @@ msgstr "" "Un⋅e administrateur⋅rice a tous les droits. Merci de ne pas donner ce droit " "à toustes les juré⋅es et bénévoles." -#: registration/models.py:459 +#: registration/models.py:458 msgid "admin" msgstr "admin" -#: registration/models.py:459 +#: registration/models.py:458 msgid "volunteer" msgstr "bénévole" -#: registration/models.py:472 +#: registration/models.py:471 msgid "" "Registrations for tournament {tournament} are closing on {date:%Y-%m-%d %H:" "%M}. There are for now {validated_teams} validated teams (+ {pending_teams} " @@ -2164,11 +2166,11 @@ msgstr "" "%M}. Il y a pour l'instant {validated_teams} équipes validées (+ " "{pending_teams} en attente) sur {max_teams} attendues." -#: registration/models.py:480 +#: registration/models.py:479 msgid "Registrations" msgstr "Inscriptions" -#: registration/models.py:487 +#: registration/models.py:486 #, python-brace-format msgid "" "The team {trigram} requested to be validated for the tournament of " @@ -2179,7 +2181,7 @@ msgstr "" "Vous pouvez vérifier le statut de l'équipe sur la page de " "l'équipe." -#: registration/models.py:504 +#: registration/models.py:503 #, python-brace-format msgid "" "There are {valid} validated payments, {pending} pending and {invalid} " @@ -2190,19 +2192,19 @@ msgstr "" "invalides pour le tournoi {tournament}. Vous pouvez vérifier le statut des " "paiements sur la liste des paiements." -#: registration/models.py:511 +#: registration/models.py:510 msgid "Payments" msgstr "Paiements" -#: registration/models.py:520 +#: registration/models.py:519 msgid "volunteer registration" msgstr "inscription de bénévole" -#: registration/models.py:521 +#: registration/models.py:520 msgid "volunteer registrations" msgstr "inscriptions de bénévoles" -#: registration/models.py:542 +#: registration/models.py:541 msgid "" "If set to true, then one payment is made for the full team, for example if " "the school pays for all." @@ -2210,100 +2212,100 @@ msgstr "" "Si vrai, alors un seul paiement est fait pour toute l'équipe, par exemple si " "le lycée paie pour tout le monde." -#: registration/models.py:547 +#: registration/models.py:546 msgid "total amount" msgstr "montant total" -#: registration/models.py:548 +#: registration/models.py:547 msgid "Corresponds to the total required amount to pay, in euros." msgstr "Correspond au montant total à payer, en euros." -#: registration/models.py:553 +#: registration/models.py:552 msgid "token" msgstr "jeton" -#: registration/models.py:556 +#: registration/models.py:555 msgid "A token to authorize external users to make this payment." msgstr "Un jeton pour autoriser des utilisateurs externes à faire ce paiement." -#: registration/models.py:560 +#: registration/models.py:559 msgid "for final tournament" msgstr "pour la finale" -#: registration/models.py:565 +#: registration/models.py:564 msgid "type" msgstr "type" -#: registration/models.py:568 +#: registration/models.py:567 msgid "No payment" msgstr "Pas de paiement" -#: registration/models.py:569 -#: registration/templates/registration/payment_form.html:70 +#: registration/models.py:568 +#: registration/templates/registration/payment_form.html:72 msgid "Credit card" msgstr "Carte bancaire" -#: registration/models.py:570 +#: registration/models.py:569 msgid "Scholarship" msgstr "Notification de bourse" -#: registration/models.py:571 -#: registration/templates/registration/payment_form.html:75 +#: registration/models.py:570 +#: registration/templates/registration/payment_form.html:77 msgid "Bank transfer" msgstr "Virement bancaire" -#: registration/models.py:572 +#: registration/models.py:571 msgid "Other (please indicate)" msgstr "Autre (veuillez spécifier)" -#: registration/models.py:573 +#: registration/models.py:572 msgid "The tournament is free" msgstr "Le tournoi est gratuit" -#: registration/models.py:580 +#: registration/models.py:579 msgid "Hello Asso checkout intent ID" msgstr "ID de l'intention de paiement Hello Asso" -#: registration/models.py:587 +#: registration/models.py:586 msgid "receipt" msgstr "justificatif" -#: registration/models.py:588 +#: registration/models.py:587 msgid "only if you have a scholarship or if you chose a bank transfer." msgstr "" "Nécessaire seulement si vous déclarez être boursièr⋅e ou si vous payez par " "virement bancaire." -#: registration/models.py:595 +#: registration/models.py:594 msgid "additional information" msgstr "informations additionnelles" -#: registration/models.py:596 +#: registration/models.py:595 msgid "To help us to find your payment." msgstr "Pour nous aider à retrouver votre paiement, si nécessaire." -#: registration/models.py:602 +#: registration/models.py:601 msgid "payment valid" msgstr "paiement valide" -#: registration/models.py:662 +#: registration/models.py:661 msgid "Reminder for your payment" msgstr "Rappel pour votre paiement" -#: registration/models.py:673 +#: registration/models.py:672 msgid "Payment confirmation" msgstr "Confirmation de paiement" -#: registration/models.py:695 +#: registration/models.py:694 #, python-brace-format msgid "Payment of {registrations}" msgstr "Paiements de {registrations}" -#: registration/models.py:698 +#: registration/models.py:697 msgid "payment" msgstr "paiement" -#: registration/models.py:699 +#: registration/models.py:698 msgid "payments" msgstr "paiements" @@ -2495,7 +2497,7 @@ msgstr "" #: registration/templates/registration/mails/payment_reminder.txt:9 #: registration/templates/registration/payment_form.html:14 msgid "This price includes the registrations of all members of your team." -msgstr "Ce prix inclut les inscriptions de tous les membres de votre équipe." +msgstr "Ce prix inclut les inscriptions de toustes les membres de votre équipe." #: registration/templates/registration/mails/payment_reminder.html:29 #: registration/templates/registration/mails/payment_reminder.txt:11 @@ -2628,7 +2630,7 @@ msgstr "" "paiement si vous avez une bourse, mais vous devez alors nous envoyer un " "justificatif de votre bourse." -#: registration/templates/registration/payment_form.html:28 +#: registration/templates/registration/payment_form.html:29 msgid "" "You want finally that each member pays its own registration? Then click on " "the button:" @@ -2636,11 +2638,11 @@ msgstr "" "Vous voulez finalement que chaque membre paie sa propre inscription ? Alors " "cliquez sur le bouton :" -#: registration/templates/registration/payment_form.html:33 +#: registration/templates/registration/payment_form.html:34 msgid "Back to single payments" msgstr "Retour aux paiements individuels" -#: registration/templates/registration/payment_form.html:37 +#: registration/templates/registration/payment_form.html:38 msgid "" "You want to pay for the registrations of all members of your team, or your " "school will pay for all registrations? Then click on the button:" @@ -2649,19 +2651,19 @@ msgstr "" "ou votre école paiera pour toutes les inscriptions ? Alors cliquez sur le " "bouton :" -#: registration/templates/registration/payment_form.html:43 +#: registration/templates/registration/payment_form.html:44 msgid "Group the payments of my team" msgstr "Regrouper les paiements de mon équipe" -#: registration/templates/registration/payment_form.html:53 +#: registration/templates/registration/payment_form.html:55 msgid "Concerned students" msgstr "Élèves concerné⋅es" -#: registration/templates/registration/payment_form.html:81 +#: registration/templates/registration/payment_form.html:83 msgid "I have a scholarship" msgstr "J'ai une bourse" -#: registration/templates/registration/payment_form.html:97 +#: registration/templates/registration/payment_form.html:99 msgid "" "The payment by credit card is made via Hello Asso. To do this, you can click " "on the button below, which will redirect you to the secure payment page of " @@ -2673,11 +2675,11 @@ msgstr "" "paiement sécurisée de Hello Asso. La validation du paiement se fera alors " "automatiquement, dans quelques minutes." -#: registration/templates/registration/payment_form.html:106 +#: registration/templates/registration/payment_form.html:108 msgid "Go to the Hello Asso page" msgstr "Aller à la page Hello Asso" -#: registration/templates/registration/payment_form.html:111 +#: registration/templates/registration/payment_form.html:113 msgid "" "If a third party must pay for you (parents, school,…), you can send them the " "link to pay for you:" @@ -2685,11 +2687,11 @@ msgstr "" "Si un tiers doit payer pour vous (parents, école, …), vous pouvez leur " "envoyer le lien pour payer pour vous :" -#: registration/templates/registration/payment_form.html:121 +#: registration/templates/registration/payment_form.html:123 msgid "Copied!" msgstr "Copié !" -#: registration/templates/registration/payment_form.html:128 +#: registration/templates/registration/payment_form.html:130 msgid "" "If this is the case and if an invoice is necessary, please contact the " "tournament organizers by providing the name of the team, the number of " @@ -2701,7 +2703,7 @@ msgstr "" "de participant⋅es, le nom de l'établissement payeur, l'adresse mail de " "l'établissement et/ou l'adresse mail du gestionnaire de l'établissement." -#: registration/templates/registration/payment_form.html:139 +#: registration/templates/registration/payment_form.html:141 msgid "" "You can also pay by bank transfer. To do this, you must put in the reference " "of the transfer \"TFJMpu\" followed by the last name and the first name of " @@ -2711,11 +2713,11 @@ msgstr "" "mettre en référence du virement « TFJMpu » suivi du nom et du prénom de " "l'élève." -#: registration/templates/registration/payment_form.html:145 +#: registration/templates/registration/payment_form.html:147 msgid "The bank details are as follows:" msgstr "Les coordonnées bancaires sont les suivantes :" -#: registration/templates/registration/payment_form.html:156 +#: registration/templates/registration/payment_form.html:158 msgid "" "Once your payment done, please send us a proof of your transfer using the " "below form. The validation of your payment will then be done manually, " @@ -2725,13 +2727,13 @@ msgstr "" "votre virement en utilisant le formulaire ci-dessous. La validation de votre " "paiement se fera alors manuellement, sous quelques jours." -#: registration/templates/registration/payment_form.html:165 -#: registration/templates/registration/payment_form.html:180 -#: registration/templates/registration/payment_form.html:195 +#: registration/templates/registration/payment_form.html:167 +#: registration/templates/registration/payment_form.html:182 +#: registration/templates/registration/payment_form.html:197 msgid "Submit" msgstr "Envoyer" -#: registration/templates/registration/payment_form.html:171 +#: registration/templates/registration/payment_form.html:173 msgid "" "The tournament is free for you if you have a scholarship. However, you must " "send us a proof of your scholarship. You can do this using the below form." @@ -2740,7 +2742,7 @@ msgstr "" "devez nous envoyer un justificatif de votre bourse. Vous pouvez le faire en " "utilisant le formulaire ci-dessous." -#: registration/templates/registration/payment_form.html:186 +#: registration/templates/registration/payment_form.html:188 msgid "" "If you want to use another payment method, please contact the tournament " "organizers first. Then, if you need to send a proof or your payment, you can " @@ -2751,6 +2753,71 @@ msgstr "" "justificatif de votre paiement, vous pouvez utiliser le formulaire ci-" "dessous." +#: registration/templates/registration/payment_form.html:217 +msgid "Your payment by credit card via Hello Asso is successfully validated." +msgstr "Votre paiement par carte bancaire via Hello Asso est validé avec succès." + +#: registration/templates/registration/payment_form.html:218 +msgid "The paid amount is" +msgstr "Le montant payé est" + +#: registration/templates/registration/payment_form.html:220 +#: registration/templates/registration/payment_form.html:241 +#: registration/templates/registration/payment_form.html:263 +msgid "It includes the registrations of all members of the team." +msgstr "Ce prix inclut les inscriptions de toustes les membres " +"de l'équipe." + +#: registration/templates/registration/payment_form.html:222 +msgid "The payer was " +msgstr "La personne qui a payé est " + +#: registration/templates/registration/payment_form.html:223 +msgid "The payment was done on" +msgstr "Le paiement a été réalisé le" + +#: registration/templates/registration/payment_form.html:228 +msgid "The payment by credit card via Hello Asso is pending validation." +msgstr "Le paiement par carte bancaire via Hello Asso est en attente " +"de validation." + +#: registration/templates/registration/payment_form.html:229 +msgid "" +"It should takes only few minutes. If it takes longer, please contact us." +msgstr "" +"Cela ne devrait prendre que quelques minutes. Si cela prend plus de temps, " +"merci de nous contacter." + +#: registration/templates/registration/payment_form.html:235 +msgid "Your payment is successfully validated by the organizers." +msgstr "Votre paiement est validé avec succès par les organisateur⋅rices." + +#: registration/templates/registration/payment_form.html:237 +#: registration/templates/registration/payment_form.html:259 +msgid "Type:" +msgstr "Type :" + +#: registration/templates/registration/payment_form.html:239 +#: registration/templates/registration/payment_form.html:261 +msgid "Amount:" +msgstr "Montant :" + +#: registration/templates/registration/payment_form.html:246 +#: registration/templates/registration/payment_form.html:268 +msgid "Receipt:" +msgstr "Justificatif :" + +#: registration/templates/registration/payment_form.html:251 +#: registration/templates/registration/payment_form.html:273 +msgid "Additional information:" +msgstr "Informations additionnelles :" + +#: registration/templates/registration/payment_form.html:257 +msgid "Your payment is pending validation from the organizers." +msgstr "" +"Votre paiement est en attente de validation par les " +"organisateur⋅rices." + #: registration/templates/registration/signup.html:5 #: registration/templates/registration/signup.html:12 #: registration/templates/registration/signup.html:19 registration/views.py:46 @@ -2965,38 +3032,45 @@ msgstr "Détails de l'utilisateur⋅rice {user}" msgid "Update user {user}" msgstr "Mise à jour de l'utilisateur⋅rice {user}" -#: registration/views.py:503 +#: registration/views.py:482 registration/views.py:516 msgid "This payment is already valid or pending validation." msgstr "Le paiement est déjà validé ou en attente de validation." -#: registration/views.py:570 +#: registration/views.py:508 +msgid "" +"Since one payment is already validated, or pending validation, grouping is " +"not possible." +msgstr "Puisque un paiement est déjà validé, ou en attente de validation, le " +"regroupement n'est pas possible." + +#: registration/views.py:583 msgid "The payment is already valid or pending validation." msgstr "Le paiement est déjà validé ou en attente de validation." -#: registration/views.py:584 +#: registration/views.py:597 msgid "The payment is not found or is already validated." msgstr "Le paiement n'est pas trouvé ou déjà validé." -#: registration/views.py:603 +#: registration/views.py:616 #, python-brace-format msgid "An error occurred during the payment: {error}" msgstr "Une erreur est survenue lors du paiement : {error}" -#: registration/views.py:609 +#: registration/views.py:622 msgid "The payment has been refused." msgstr "Le paiement a été refusé." -#: registration/views.py:612 +#: registration/views.py:625 #, python-brace-format msgid "The return code is unknown: {code}" msgstr "Le code de retour est inconnu : {code}" -#: registration/views.py:615 +#: registration/views.py:628 #, python-brace-format msgid "The return type is unknown: {type}" msgstr "Le type de retour est inconnu : {type}" -#: registration/views.py:624 +#: registration/views.py:637 msgid "" "The payment has been successfully validated! Your registration is now " "complete." @@ -3004,7 +3078,7 @@ msgstr "" "Le paiement a été validé avec succès ! Votre inscription est désormais " "complète." -#: registration/views.py:631 +#: registration/views.py:644 msgid "" "Your payment is done! The validation of your payment may takes a few " "minutes, and will be automatically done. If it is not the case, please " @@ -3014,27 +3088,27 @@ msgstr "" "quelques minutes, et sera faite automatiquement. Si ce n'est pas le cas, " "merci de nous contacter." -#: registration/views.py:662 +#: registration/views.py:675 #, python-brace-format msgid "Photo authorization of {student}.{ext}" msgstr "Autorisation de droit à l'image de {student}.{ext}" -#: registration/views.py:686 +#: registration/views.py:699 #, python-brace-format msgid "Health sheet of {student}.{ext}" msgstr "Fiche sanitaire de {student}.{ext}" -#: registration/views.py:710 +#: registration/views.py:723 #, python-brace-format msgid "Vaccine sheet of {student}.{ext}" msgstr "Carnet de vaccination de {student}.{ext}" -#: registration/views.py:734 +#: registration/views.py:747 #, python-brace-format msgid "Parental authorization of {student}.{ext}" msgstr "Autorisation parentale de {student}.{ext}" -#: registration/views.py:757 +#: registration/views.py:770 #, python-brace-format msgid "Payment receipt of {user}.{ext}" msgstr "Justificatif de paiement de {user}.{ext}" diff --git a/registration/templates/registration/payment_form.html b/registration/templates/registration/payment_form.html index 33c1557..b349481 100644 --- a/registration/templates/registration/payment_form.html +++ b/registration/templates/registration/payment_form.html @@ -201,13 +201,82 @@ {% else %} -
-
- {% csrf_token %} - {{ form|crispy }} -
- -
+ {% if user.registration.is_volunteer %} +
+
+ {% csrf_token %} + {{ form|crispy }} +
+ +
+ {% else %} + {% if payment.type == 'helloasso' %} + {% if payment.valid is True %} +
+ {% with order=payment.get_checkout_intent.order %} + {% trans "Your payment by credit card via Hello Asso is successfully validated." %} + {% trans "The paid amount is" %} {% widthratio order.amount.total 100 1 %} €. + {% if grouped %} + {% trans "It includes the registrations of all members of the team." %} + {% endif %} + {% trans "The payer was " %} {{ order.payer.firstName }} {{ order.payer.lastName }}. + {% trans "The payment was done on" %} {{ order.date }}. + {% endwith %} +
+ {% elif payment.valid is None %} +
+ {% trans "The payment by credit card via Hello Asso is pending validation." %} + {% trans "It should takes only few minutes. If it takes longer, please contact us." %} +
+ {% endif %} + {% else %} + {% if payment.valid is True %} +
+ {% trans "Your payment is successfully validated by the organizers." %} +
    +
  • {% trans "Type:" %} {{ payment.get_type_display }}
  • +
  • + {% trans "Amount:" %} {{ payment.amount }} € + {% if payment.grouped %} + ({% trans "It includes the registrations of all members of the team." %}) + {% endif %} +
  • + {% if payment.receipt %} +
  • + {% trans "Receipt:" %} + {% trans "Download" %} +
  • + {% endif %} + {% if payment.additional_information %} +
  • {% trans "Additional information:" %} {{ payment.additional_information }}
  • + {% endif %} +
+
+ {% elif payment.valid is None %} +
+ {% trans "Your payment is pending validation from the organizers." %} +
    +
  • {% trans "Type:" %} {{ payment.get_type_display }}
  • +
  • + {% trans "Amount:" %} {{ payment.amount }} € + {% if payment.grouped %} + ({% trans "It includes the registrations of all members of the team." %}) + {% endif %} +
  • + {% if payment.receipt %} +
  • + {% trans "Receipt:" %} + {% trans "Download" %} +
  • + {% endif %} + {% if payment.additional_information %} +
  • {% trans "Additional information:" %} {{ payment.additional_information }}
  • + {% endif %} +
+
+ {% endif %} + {% endif %} + {% endif %} {% endif %} {% endblock content %} diff --git a/registration/views.py b/registration/views.py index 08e08c6..e0dc265 100644 --- a/registration/views.py +++ b/registration/views.py @@ -451,8 +451,7 @@ class PaymentUpdateView(LoginRequiredMixin, UpdateView): def dispatch(self, request, *args, **kwargs): if not self.request.user.is_authenticated or \ not self.request.user.registration.is_admin \ - and (self.request.user.registration not in self.get_object().registrations.all() - or self.get_object().valid is not False): + and self.request.user.registration not in self.get_object().registrations.all(): return self.handle_no_permission() return super().dispatch(request, *args, **kwargs) @@ -477,8 +476,12 @@ class PaymentUpdateView(LoginRequiredMixin, UpdateView): return context def form_valid(self, form): - form.instance.valid = None old_instance = Payment.objects.get(pk=self.object.pk) + if self.request.user.registration.participates: + if old_instance.valid is not False: + raise PermissionDenied(_("This payment is already valid or pending validation.")) + else: + form.instance.valid = None if old_instance.receipt: old_instance.receipt.delete() old_instance.save()