The main functionality of it would be:

  1. check a condition every day
  2. if the condition is true, then send email

Now, I know how to conditionlly send email, but I don`t know how to do make it repeat every day. I have some ideas but not sure about them at all (to add another process? or others?). I appreciate your suggestions and ideas...thx

有帮助吗?

解决方案

You could create a custom management command and use a cron job to have it run once a day.

edit:

I have used this before, http://code.google.com/p/django-command-extensions/wiki/JobsScheduling. It is pretty handy if you have multiple tasks to be run on fixed schedules. Instead of having to add a line in crontab for each task you just add new files to the jobs directory.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top