def get(self): q = Stage.query() stages=[] for stage in q: stages.append(json.loads(stage.data)) self.response.headers['Content-Type'] = 'application/json' self.response.out.write(json.dumps(stages))
def get(self): self.response.out.write("Getting stages info </br>") generate_tour_data() q = Stage.query() for stage in q: d = json.loads(stage.data) # Add the task to the default queue. taskqueue.add(url='/details', params={'stage_key': stage.key.id(),'stage_link':d["stage-link"]}) taskqueue.add(url='/clasification', params={'stage_key': stage.key.id()}) taskqueue.add(url='/image', params={}) self.response.out.write("Created Task for stage number: <b>"+str(stage.key.id())+"</b></br>")