def handle(self, **options): if not options['slug']: slug = raw_input('Script slug you wish to reschedule: ') else: slug = options['slug'] script = Script.objects.get(slug=slug) schedule_script(script) self.stdout.write('Done!\n')
def handle(self, **options): for script in Script.objects.all(): schedule_script(script) self.stdout.write('Done!\n')