Пример #1
0
 def get(self):
     s = Sensor.by_id(self.request.GET['sensor'])
     s.hours = [timeof(x) for x in self.request.GET['time'].split(',')]
     s.put()
     self.response.write(s)
Пример #2
0
 def get(self):
     template = env.get_template('chart.html')
     s = Sensor.by_id(self.request.GET['sensor'])
     self.response.write(template.render(sensor=self.request.GET['sensor'], sensor_name=s.name, hours=True))