Ejemplo n.º 1
0
 def createTask(self):
     import json
     task = Task()
     task.run_time = json.dumps({'minutes':10})
     task.name = 'name'
     task.run_entry = self.url
     return task
Ejemplo n.º 2
0
 def generateTask(self):
     task = Task()
     task.name = 'Task1'
     task.run_time = '{"days":0, "hours":0, "minutes":10, "seconds":0}'
     task.run_entry = 'http://baidu.com'
     task.run_method = 'post'
     task.active = 1
     return task