Example #1
0
 def get(self):
   pub_id = int(self.request.get('pub'))
   pub = Pub.get_by_id(pub_id)
   visits = Visit.all().filter('pub =', pub).run()
   for v in visits:
     v.delete()
   pub.delete()
Example #2
0
 def get(self):
   pub_id = int(self.request.get('pub'))
   pub = Pub.get_by_id(pub_id)
   pub.closed = True
   pub.put()