예제 #1
0
 def get(self):
     current = Election.gql("ORDER BY created DESC LIMIT 10")
     self.render("list.html", elections=current)
예제 #2
0
 def get(self):
     current = Election.gql("ORDER BY created DESC LIMIT 10")
     self.render("list.html", elections=current)
예제 #3
0
 def get(self):
     now = datetime.now()
     current = Election.gql(
         "WHERE approved = True AND closes > :1 ORDER BY closes LIMIT 10",
         now)
     self.render("index.html", elections=current)
예제 #4
0
 def get(self):
     now = datetime.now()
     current = Election.gql("WHERE approved = True AND closes > :1 ORDER BY closes LIMIT 10", now)
     self.render("index.html", elections=current)