forked from ScoDoc/DocScoDoc
Message erreur si bul_intro_mail invalide
This commit is contained in:
parent
2cac0031f6
commit
6a07bb85a0
@ -1013,11 +1013,16 @@ def mail_bulletin(formsemestre_id, I, pdfdata, filename, recipient_addr):
|
||||
intro_mail = sco_preferences.get_preference("bul_intro_mail", formsemestre_id)
|
||||
|
||||
if intro_mail:
|
||||
hea = intro_mail % {
|
||||
"nomprenom": etud["nomprenom"],
|
||||
"dept": dept,
|
||||
"webmaster": webmaster,
|
||||
}
|
||||
try:
|
||||
hea = intro_mail % {
|
||||
"nomprenom": etud["nomprenom"],
|
||||
"dept": dept,
|
||||
"webmaster": webmaster,
|
||||
}
|
||||
except KeyError as e:
|
||||
raise ScoValueError(
|
||||
"format 'Message d'accompagnement' (bul_intro_mail) invalide, revoir les réglages dans les préférences"
|
||||
)
|
||||
else:
|
||||
hea = ""
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user