本文整理汇总了Python中models.Event.get_all_future_list方法的典型用法代码示例。如果您正苦于以下问题:Python Event.get_all_future_list方法的具体用法?Python Event.get_all_future_list怎么用?Python Event.get_all_future_list使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类models.Event
的用法示例。
在下文中一共展示了Event.get_all_future_list方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: get
# 需要导入模块: from models import Event [as 别名]
# 或者: from models.Event import get_all_future_list [as 别名]
def get(self):
user = users.get_current_user()
if user:
logout_url = users.create_logout_url('/')
else:
login_url = users.create_login_url('/')
show_all_nav = user
events = Event.get_all_future_list()
today = local_today()
tomorrow = today + timedelta(days=1)
self.response.out.write(template.render('templates/all_future.html', locals()))
示例2: get
# 需要导入模块: from models import Event [as 别名]
# 或者: from models.Event import get_all_future_list [as 别名]
def get(self):
user = users.get_current_user()
if user:
logout_url = users.create_logout_url("/")
else:
login_url = users.create_login_url("/")
show_all_nav = user
events = Event.get_all_future_list()
today = local_today()
tomorrow = today + timedelta(days=1)
# this is not the permanent answer but just for now
cdn = "http://cdn.hackerdojo.com"
self.response.out.write(template.render("templates/all_future.html", locals()))