Encore des conneries
darcs-hash:20040905213504-d1718-f80e46f82a6dcaefee398f2188b137995e109ad3.gz
This commit is contained in:
parent
21ddceafe7
commit
a9c7f1b23f
2 changed files with 6 additions and 3 deletions
|
@ -78,8 +78,11 @@ class switch(gen_config) :
|
|||
conn=smtplib.SMTP('localhost')
|
||||
txt_mail = "From: Crans scripts <%(From)s>\n"
|
||||
txt_mail+= "To: %(To)s\n"
|
||||
txt_mail+= "Subject: Bienvenue au Cr@ns !\n\n"
|
||||
txt_mail+= "Chambre %s à débrancher." % chbre
|
||||
txt_mail+= "Subject: (CRANS) Changement d'état d'une chambre !\n\n"
|
||||
if action == 'disable':
|
||||
txt_mail+= "Chambre %s à débrancher." % chbre
|
||||
else:
|
||||
txt_mail+= "Chambre %s à brancher." % chbre
|
||||
conn.sendmail(From, To , txt_mail % { 'From' : From, 'To' : To })
|
||||
conn.quit()
|
||||
print OK
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue