comparison gpp/mailer/management/commands/send_mail.py @ 180:aef00df91165

Implement #63, add a queued email facility.
author Brian Neal <bgneal@gmail.com>
date Sun, 21 Mar 2010 20:33:33 +0000
parents
children
comparison
equal deleted inserted replaced
179:70b2e307c866 180:aef00df91165
1 """send_mail is a custom manage.py command for the mailer application.
2 It is intended to be called from a cron job periodically to send out queued
3 email in bulk. This avoids doing the mailing on the HTTP request processing.
4 """
5 from django.core.management.base import NoArgsCommand
6
7 import mailer
8
9
10 class Command(NoArgsCommand):
11 help = "Run periodically to send out queued email."
12
13 def handle_noargs(self, **options):
14 mailer.send_queued_mail()
15