mirror of
https://gitlab.com/animath/si/plateforme.git
synced 2025-02-23 13:41:18 +00:00
Compare commits
4 Commits
99a2134a57
...
69325bff9a
Author | SHA1 | Date | |
---|---|---|---|
69325bff9a | |||
049234caae | |||
f8d38738ea | |||
f7d52aa6da |
@ -10,14 +10,25 @@ import requests
|
||||
|
||||
class Command(BaseCommand):
|
||||
def handle(self, *args, **options): # noqa: C901
|
||||
# Get access token
|
||||
response = requests.post('https://api.helloasso.com/oauth2/token', headers={
|
||||
'Content-Type': 'application/x-www-form-urlencoded',
|
||||
}, data={
|
||||
'client_id': os.getenv('HELLOASSO_CLIENT_ID', ''),
|
||||
'client_secret': os.getenv('HELLOASSO_CLIENT_SECRET', ''),
|
||||
'grant_type': 'client_credentials',
|
||||
}).json()
|
||||
|
||||
token = response['access_token']
|
||||
|
||||
organization = "animath"
|
||||
form_slug = "tfjmm-2018"
|
||||
form_slug = "tfjm-2021"
|
||||
from_date = "2000-01-01"
|
||||
url = f"https://api.helloasso.com/v5/organizations/{organization}/forms/Event/{form_slug}/payments" \
|
||||
f"?from={from_date}&pageIndex=1&pageSize=10000&retrieveOfflineDonations=false"
|
||||
headers = {
|
||||
"Accept": "application/json",
|
||||
"Authorization": f"Bearer {os.getenv('HELLO_ASSO_TOKEN', '')}",
|
||||
"Authorization": f"Bearer {token}",
|
||||
}
|
||||
http_response = requests.get(url, headers=headers)
|
||||
response = http_response.json()
|
||||
@ -27,7 +38,7 @@ class Command(BaseCommand):
|
||||
self.stderr.write(f"Error while querying Hello Asso: {message}")
|
||||
return
|
||||
|
||||
for payment in response:
|
||||
for payment in response["data"]:
|
||||
if payment["state"] != "Authorized":
|
||||
continue
|
||||
|
||||
|
@ -16,7 +16,7 @@
|
||||
<p>
|
||||
{% blocktrans trimmed %}
|
||||
You can pay with a credit card through
|
||||
<a class="alert-link" href="https://www.helloasso.com/associations/animath/evenements/tfjmm-2018">our Hello Asso page</a>.
|
||||
<a class="alert-link" href="https://www.helloasso.com/associations/animath/evenements/tfjm-2021">our Hello Asso page</a>.
|
||||
To make the validation of the payment easier, <span class="text-danger">please use the same e-mail
|
||||
address that you use on this platform.</span> The payment verification will be checked automatically
|
||||
under 10 minutes, you don't necessary need to fill this form.
|
||||
|
@ -73,7 +73,7 @@ Si le paiement de plusieurs élèves est fait en une seule opération, merci de
|
||||
\href{mailto: contact@tfjm.org}{contact@tfjm.org} \textbf{avant le paiement} pour garantir l'identification de ce dernier.
|
||||
|
||||
\subsubsection*{Carte bancaire (uniquement les cartes françaises)}
|
||||
Le paiement s'effectue en ligne via la plateforme à l'adresse : \url{https://www.helloasso.com/associations/animath/evenements/tfjmm-2021}
|
||||
Le paiement s'effectue en ligne via la plateforme à l'adresse : \url{https://www.helloasso.com/associations/animath/evenements/tfjm-2021}
|
||||
|
||||
Vous devez impérativement indiquer dans le champ "Référence" la mention "TFJMpu" suivie des noms et prénoms \textbf{de l'élève}.
|
||||
|
||||
|
@ -7,7 +7,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: TFJM\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2021-02-07 17:38+0100\n"
|
||||
"POT-Creation-Date: 2021-03-15 10:16+0100\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: Yohann D'ANELLO <yohann.danello@animath.fr>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
@ -859,7 +859,7 @@ msgid "Invalidate"
|
||||
msgstr "Invalider"
|
||||
|
||||
#: apps/participation/templates/participation/team_detail.html:169
|
||||
#: apps/participation/views.py:324
|
||||
#: apps/participation/views.py:323
|
||||
msgid "Upload motivation letter"
|
||||
msgstr "Envoyer la lettre de motivation"
|
||||
|
||||
@ -868,7 +868,7 @@ msgid "Update team"
|
||||
msgstr "Modifier l'équipe"
|
||||
|
||||
#: apps/participation/templates/participation/team_detail.html:179
|
||||
#: apps/participation/views.py:425
|
||||
#: apps/participation/views.py:424
|
||||
msgid "Leave team"
|
||||
msgstr "Quitter l'équipe"
|
||||
|
||||
@ -990,12 +990,12 @@ msgstr "Vous êtes déjà dans une équipe."
|
||||
msgid "Join team"
|
||||
msgstr "Rejoindre une équipe"
|
||||
|
||||
#: apps/participation/views.py:150 apps/participation/views.py:431
|
||||
#: apps/participation/views.py:464
|
||||
#: apps/participation/views.py:150 apps/participation/views.py:430
|
||||
#: apps/participation/views.py:463
|
||||
msgid "You are not in a team."
|
||||
msgstr "Vous n'êtes pas dans une équipe."
|
||||
|
||||
#: apps/participation/views.py:151 apps/participation/views.py:465
|
||||
#: apps/participation/views.py:151 apps/participation/views.py:464
|
||||
msgid "You don't participate, so you don't have any team."
|
||||
msgstr "Vous ne participez pas, vous n'avez donc pas d'équipe."
|
||||
|
||||
@ -1004,17 +1004,17 @@ msgstr "Vous ne participez pas, vous n'avez donc pas d'équipe."
|
||||
msgid "Detail of team {trigram}"
|
||||
msgstr "Détails de l'équipe {trigram}"
|
||||
|
||||
#: apps/participation/views.py:212
|
||||
#: apps/participation/views.py:211
|
||||
msgid "You don't participate, so you can't request the validation of the team."
|
||||
msgstr ""
|
||||
"Vous ne participez pas, vous ne pouvez pas demander la validation de "
|
||||
"l'équipe."
|
||||
|
||||
#: apps/participation/views.py:215
|
||||
#: apps/participation/views.py:214
|
||||
msgid "The validation of the team is already done or pending."
|
||||
msgstr "La validation de l'équipe est déjà faite ou en cours."
|
||||
|
||||
#: apps/participation/views.py:218
|
||||
#: apps/participation/views.py:217
|
||||
msgid ""
|
||||
"The team can't be validated: missing email address confirmations, "
|
||||
"authorizations, people, motivation letter or the tournament is not set."
|
||||
@ -1023,66 +1023,66 @@ msgstr ""
|
||||
"d'adresse e-mail, soit une autorisation, soit des personnes, soit la lettre "
|
||||
"de motivation, soit le tournoi n'a pas été choisi."
|
||||
|
||||
#: apps/participation/views.py:240
|
||||
#: apps/participation/views.py:239
|
||||
msgid "You are not an organizer of the tournament."
|
||||
msgstr "Vous n'êtes pas un organisateur du tournoi."
|
||||
|
||||
#: apps/participation/views.py:243
|
||||
#: apps/participation/views.py:242
|
||||
msgid "This team has no pending validation."
|
||||
msgstr "L'équipe n'a pas de validation en attente."
|
||||
|
||||
#: apps/participation/views.py:273
|
||||
#: apps/participation/views.py:272
|
||||
msgid "You must specify if you validate the registration or not."
|
||||
msgstr "Vous devez spécifier si vous validez l'inscription ou non."
|
||||
|
||||
#: apps/participation/views.py:304
|
||||
#: apps/participation/views.py:303
|
||||
#, python-brace-format
|
||||
msgid "Update team {trigram}"
|
||||
msgstr "Mise à jour de l'équipe {trigram}"
|
||||
|
||||
#: apps/participation/views.py:362 apps/participation/views.py:411
|
||||
#: apps/participation/views.py:361 apps/participation/views.py:410
|
||||
#, python-brace-format
|
||||
msgid "Motivation letter of {team}.{ext}"
|
||||
msgstr "Lettre de motivation de {team}.{ext}"
|
||||
|
||||
#: apps/participation/views.py:392
|
||||
#: apps/participation/views.py:391
|
||||
#, python-brace-format
|
||||
msgid "Photo authorization of {participant}.{ext}"
|
||||
msgstr "Autorisation de droit à l'image de {participant}.{ext}"
|
||||
|
||||
#: apps/participation/views.py:398
|
||||
#: apps/participation/views.py:397
|
||||
#, python-brace-format
|
||||
msgid "Parental authorization of {participant}.{ext}"
|
||||
msgstr "Autorisation parentale de {participant}.{ext}"
|
||||
|
||||
#: apps/participation/views.py:405
|
||||
#: apps/participation/views.py:404
|
||||
#, python-brace-format
|
||||
msgid "Health sheet of {participant}.{ext}"
|
||||
msgstr "Fiche sanitaire de {participant}.{ext}"
|
||||
|
||||
#: apps/participation/views.py:415
|
||||
#: apps/participation/views.py:414
|
||||
#, python-brace-format
|
||||
msgid "Photo authorizations of team {trigram}.zip"
|
||||
msgstr "Autorisations de droit à l'image de l'équipe {trigram}.zip"
|
||||
|
||||
#: apps/participation/views.py:433
|
||||
#: apps/participation/views.py:432
|
||||
msgid "The team is already validated or the validation is pending."
|
||||
msgstr "La validation de l'équipe est déjà faite ou en cours."
|
||||
|
||||
#: apps/participation/views.py:479
|
||||
#: apps/participation/views.py:478
|
||||
msgid "The team is not validated yet."
|
||||
msgstr "L'équipe n'est pas encore validée."
|
||||
|
||||
#: apps/participation/views.py:491
|
||||
#: apps/participation/views.py:490
|
||||
#, python-brace-format
|
||||
msgid "Participation of team {trigram}"
|
||||
msgstr "Participation de l'équipe {trigram}"
|
||||
|
||||
#: apps/participation/views.py:580
|
||||
#: apps/participation/views.py:579
|
||||
msgid "You can't upload a solution after the deadline."
|
||||
msgstr "Vous ne pouvez pas envoyer de solution après la date limite."
|
||||
|
||||
#: apps/participation/views.py:761
|
||||
#: apps/participation/views.py:760
|
||||
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."
|
||||
|
||||
@ -1314,7 +1314,7 @@ msgstr "nom de famille"
|
||||
|
||||
#: apps/registration/templates/registration/add_organizer.html:5
|
||||
#: apps/registration/templates/registration/add_organizer.html:12
|
||||
#: apps/registration/templates/registration/add_organizer.html:19
|
||||
#: apps/registration/templates/registration/add_organizer.html:21
|
||||
#: apps/registration/templates/registration/user_list.html:8
|
||||
#: apps/registration/views.py:88
|
||||
msgid "Add organizer"
|
||||
@ -1482,7 +1482,7 @@ msgstr ""
|
||||
#: apps/registration/templates/registration/payment_form.html:17
|
||||
msgid ""
|
||||
"You can pay with a credit card through <a class=\"alert-link\" href="
|
||||
"\"https://www.helloasso.com/associations/animath/evenements/tfjmm-2018\">our "
|
||||
"\"https://www.helloasso.com/associations/animath/evenements/tfjm-2021\">our "
|
||||
"Hello Asso page</a>. To make the validation of the payment easier, <span "
|
||||
"class=\"text-danger\">please use the same e-mail address that you use on "
|
||||
"this platform.</span> The payment verification will be checked automatically "
|
||||
@ -1490,7 +1490,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Vous pouvez payer par carte bancaire sur <a class=\"alert-link\" href="
|
||||
"\"https://www.helloasso.com/associations/animath/evenements/"
|
||||
"tfjmm-2018\">notre page Hello Asso</a>. Pour rendre la validation du "
|
||||
"tfjm-2021\">notre page Hello Asso</a>. Pour rendre la validation du "
|
||||
"paiement plus facile, <span class=\"text-danger\">merci d'utiliser la même "
|
||||
"adresse e-mail que vous utilisez sur cette plateforme.</span> La "
|
||||
"vérification du paiement sera faite automatiquement sous 10 minutes, vous "
|
||||
@ -1898,6 +1898,3 @@ msgstr "Résultats"
|
||||
#: tfjm/templates/search/search.html:25
|
||||
msgid "No results found."
|
||||
msgstr "Aucun résultat."
|
||||
|
||||
#~ msgid "Update user"
|
||||
#~ msgstr "Modifier l'utilisateur"
|
||||
|
Loading…
x
Reference in New Issue
Block a user