Skip to content

Instantly share code, notes, and snippets.

@dirn
Created May 1, 2015 03:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dirn/43c59f05d7e7d2b1e3f6 to your computer and use it in GitHub Desktop.
Save dirn/43c59f05d7e7d2b1e3f6 to your computer and use it in GitHub Desktop.
"""The PyGotham home page."""
from flask import Blueprint, render_template
from pygotham.news import get_active
from pygotham.sponsors import get_accepted
__all__ = ('blueprint',)
blueprint = Blueprint(
'home',
__name__,
static_folder='static',
static_url_path='/frontend/static',
url_prefix='/<event_slug>'
)
@blueprint.route('/')
def index():
"""Return the home page."""
announcements = get_active()
sponsors = get_accepted()
return render_template(
'home/index.html', announcements=announcements, sponsors=sponsors)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment