Closed WesleyJohnson closed 2 years ago
One way to solve your problem though is to have your app/project implement a model that has the enable/disable switch as a BooleanField
, then have your do()
method in the cronjob class check that value and only actually do anything if the conditions are right.
I would vote to not implement this feature, since it seems like bloat.
We are not currently planning such functionality, perhaps in the future.
It would be nice to be able to disable/enable crons without editing CRON_CLASSES in the settings file. I was thinking perhaps having the crons listed in the database with a flag to toggle them on/off. I realize the code that the a cron calls could implement something, but it would be preferred to control it directly from django-cron.