Changeset 7223 for main/waeup.sirp/trunk/src/waeup/sirp
- Timestamp:
- 27 Nov 2011, 08:07:01 (13 years ago)
- Location:
- main/waeup.sirp/trunk/src/waeup/sirp
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/trunk/src/waeup/sirp/browser/pages.py
r7222 r7223 463 463 pnav = 2 464 464 465 @property 466 def config(self): 467 return grok.getSite()['configuration'] 468 465 469 def title(self): 466 470 """Return True if the calling user is authenticated. … … 468 472 userid = self.request.principal.id 469 473 if userid != 'zope.anybody': 470 tt = u'Contact '474 tt = u'Contact %s' % self.config.name_admin 471 475 else: 472 476 tt = u'Enquiries' … … 510 514 msg = MIMEText(text % (fullname,regno,descr)) 511 515 msg['From'] = '%s <%s>' % (fullname,email) 512 513 config = grok.getSite()['configuration'] 514 msg['To'] = config.email_admin 515 msg['Subject'] = config.email_subject 516 server = smtplib.SMTP(config.smtp_server) 517 if config.smtp_requires_login: 518 server.login(config.smtp_username,config.smtp_password) 519 server.sendmail(email,config.email_admin,msg.as_string()) 516 517 msg['To'] = self.config.email_admin 518 msg['Subject'] = self.config.email_subject 519 server = smtplib.SMTP(self.config.smtp_server) 520 if self.config.smtp_requires_login: 521 server.login(self.config.smtp_username,self.config.smtp_password) 522 server.sendmail(email,self.config.email_admin,msg.as_string()) 520 523 521 524 server.quit() -
main/waeup.sirp/trunk/src/waeup/sirp/interfaces.py
r7222 r7223 311 311 ) 312 312 313 name_admin = schema.TextLine( 314 title = u'Name of Administrator', 315 default = u'Administrator', 316 required = False, 317 ) 318 313 319 email_admin = schema.ASCIILine( 314 title = u'Email ',320 title = u'Email Address of Administrator', 315 321 default = 'contact@waeup.org', 316 322 required = False,
Note: See TracChangeset for help on using the changeset viewer.