Changeset 42 for emailtotracscript/trunk/email2trac.py.in
- Timestamp:
- 01/25/06 18:03:57 (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
emailtotracscript/trunk/email2trac.py.in
r41 r42 135 135 else: 136 136 self.EMAIL_HEADER = 0 137 138 if parameters.has_key('alternate_notify_template'): 139 self.notify_template = str(parameters['alternate_notify_template']) 140 else: 141 self.notify_template = None 137 142 138 143 … … 280 285 281 286 author, email_addr = email.Utils.parseaddr(msg['from']) 282 email_str = self.to_unicode( email_addr)287 email_str = self.to_unicode(msg['from']) 283 288 if author: 284 tkt['reporter'] = self.to_unicode(author)285 else: 286 tkt['reporter'] = self.to_unicode(email_str)289 tkt['reporter'] = email_str 290 else: 291 tkt['reporter'] = email_str 287 292 288 293 if self.CC: … … 356 361 357 362 tn = TicketNotifyEmail(self.env) 363 if self.notify_template: 364 tn.template_name = self.notify_template; 365 358 366 tn.notify(tkt, newticket=True) 359 367 360 368 except Exception, e: 361 print "TD: Failure sending notification on creation of ticket #%s: %s" % (tkt.id, e) 369 print 'TD: Failure sending notification on creation of ticket #%s: %s' \ 370 % (tkt['id'], e) 362 371 363 372 def mail_line(self, str):
Note: See TracChangeset
for help on using the changeset viewer.