WIP: contrôle cotisation

This commit is contained in:
Adrien Bourmault 2022-09-15 00:20:06 +02:00
parent e9f7236da3
commit c8bc25dbd7
No known key found for this signature in database
GPG Key ID: 6EB408FE0ACEC664
1 changed files with 14 additions and 4 deletions

View File

@ -239,12 +239,22 @@ def renotify_unpaid(member):
# Get member infos # Get member infos
name, numero, email = get_member_infos(member) name, numero, email = get_member_infos(member)
amount = gestion_get_amount(member) amount = "{},{}".format(str(gestion_get_amount(member))[:-2],
str(gestion_get_amount(member))[-2:])
year = gestion_get_year(member)[:4]
BUF.append("* {} (numero {}), {}, {}".format(member, numero, name, amount)) BUF.append("* {} (numero {}), {}, {}".format(member, numero, name, amount))
BUF.append(" RENOTIFICATION MEMBRE") BUF.append(" NOTIFICATION MEMBRE")
BUF.append("") BUF.append("")
pass
mailtext = get_file_content_all(MODALITY_MAIL) + "\n"
mailtext = mailtext.replace("NOM_COTISANT", name)
mailtext = mailtext.replace("NUMERO_MEMBRE", numero)
mailtext = mailtext.replace("MONTANT_COTISATION", amount)
mailheaders = get_file_content_all(MODALITY_MAIL_HEADERS).replace("ANNEE_CIVILE", year)
mailheaders = mailheaders.replace("COURRIEL-COTISANT", email)
sendmail(mailheaders, mailtext)
def check_expired_unpaid(): def check_expired_unpaid():
expired_members = gestion_get_expired() expired_members = gestion_get_expired()