django-orchestra/orchestra/contrib/mailboxes/actions.py

14 lines
357 B
Python
Raw Normal View History

2014-11-27 19:17:26 +00:00
from orchestra.admin.actions import SendEmail
class SendMailboxEmail(SendEmail):
2015-05-05 19:42:55 +00:00
def get_email_addresses(self):
2014-11-27 19:17:26 +00:00
for mailbox in self.queryset.all():
yield mailbox.get_local_address()
2015-05-05 19:42:55 +00:00
class SendAddressEmail(SendEmail):
def get_email_addresses(self):
for address in self.queryset.all():
yield address.emails