django-orchestra/orchestra/contrib/mailer/management/commands/sendpendingmessages.py

15 lines
320 B
Python
Raw Normal View History

2015-05-04 19:52:53 +00:00
import json
from django.core.management.base import BaseCommand, CommandError
2015-05-07 19:00:02 +00:00
from orchestra.contrib.tasks.decorators import keep_state
2015-05-04 19:52:53 +00:00
from ...engine import send_pending
2015-05-07 19:00:02 +00:00
2015-05-04 19:52:53 +00:00
class Command(BaseCommand):
help = 'Runs Orchestra method.'
def handle(self, *args, **options):
2015-05-07 19:00:02 +00:00
keep_state(send_pending)()