|
15 | 15 | # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, |
16 | 16 | # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. |
17 | 17 | # |
18 | | -# $Id: roundupdb.py,v 1.50 2002-04-08 03:40:31 richard Exp $ |
| 18 | +# $Id: roundupdb.py,v 1.51 2002-04-08 03:46:42 richard Exp $ |
19 | 19 |
|
20 | 20 | __doc__ = """ |
21 | 21 | Extending hyperdb with types specific to issue-tracking. |
@@ -343,6 +343,9 @@ def nosymessage(self, nodeid, msgid, change_note): |
343 | 343 |
|
344 | 344 | # we have new recipients |
345 | 345 | if sendto: |
| 346 | + # map userids to addresses |
| 347 | + sendto = [users.get(i, 'address') for i in sendto] |
| 348 | + |
346 | 349 | # update the message's recipients list |
347 | 350 | messages.set(msgid, recipients=recipients) |
348 | 351 |
|
@@ -372,14 +375,11 @@ def send_message(self, nodeid, msgid, note, sendto): |
372 | 375 | self.classname, nodeid, self.db.config.MAIL_DOMAIN) |
373 | 376 | messages.set(msgid, messageid=messageid) |
374 | 377 |
|
375 | | - # figure the author's id |
376 | | - authid = messages.get(msgid, 'author') |
377 | | - |
378 | 378 | # send an email to the people who missed out |
379 | | - sendto = [users.get(i, 'address') for i in sendto] |
380 | 379 | cn = self.classname |
381 | 380 | title = self.get(nodeid, 'title') or '%s message copy'%cn |
382 | 381 | # figure author information |
| 382 | + authid = messages.get(msgid, 'author') |
383 | 383 | authname = users.get(authid, 'realname') |
384 | 384 | if not authname: |
385 | 385 | authname = users.get(authid, 'username') |
@@ -620,6 +620,15 @@ def generateChangeNote(self, nodeid, oldvalues): |
620 | 620 |
|
621 | 621 | # |
622 | 622 | # $Log: not supported by cvs2svn $ |
| 623 | +# Revision 1.50 2002/04/08 03:40:31 richard |
| 624 | +# . added a "detectors" directory for people to put their useful auditors and |
| 625 | +# reactors in. Note - the roundupdb.IssueClass.sendmessage method has been |
| 626 | +# split and renamed "nosymessage" specifically for things like the nosy |
| 627 | +# reactor, and "send_message" which just sends the message. |
| 628 | +# |
| 629 | +# The initial detector is one that we'll be using here at ekit - it bounces new |
| 630 | +# issue messages to a team address. |
| 631 | +# |
623 | 632 | # Revision 1.49 2002/03/19 06:41:49 richard |
624 | 633 | # Faster, easier, less mess ;) |
625 | 634 | # |
|
0 commit comments