Answer the question
In order to leave comments, you need to log in
Django - Sending email on a specific date (event)?
Good afternoon!
I am using django_bootstrap_calendar
models.py
class CalendarEvent(models.Model):
title = models.CharField(max_length=255, verbose_name=_('Title'))
url = models.URLField(verbose_name=_('URL'))
start = models.DateTimeField(verbose_name=_('Start Date'))
end = models.DateTimeField(verbose_name=_('End Date'), blank=True)
Answer the question
In order to leave comments, you need to log in
I did this:
- connected 'smsaero',
- in the form of adding a new event, added send_sms, in my case:
title = title.encode('utf-8')
start = int(mktime(start.timetuple()))
send_sms((resp.profile.phone), (title), '2', (start))
django.core.management.base.BaseCommand + crontab
something like this
as an option, the celery monster that can run scheduled tasks or you can use uwsgi, he can do it too
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question