def index(): newsPosts = db_session.query(NewsPost).all() if len(newsPosts) > 0: top = newsPosts[len(newsPosts) - 1] no_news = False else: no_news = True top = 0 return render_template('index.html', NEWS=top, NO_NEWS=no_news)
def index(): newsPosts = db_session.query(NewsPost).all() if len(newsPosts) > 0: top = newsPosts[len(newsPosts)-1] no_news = False else: no_news = True top = 0 return render_template('index.html', NEWS=top, NO_NEWS = no_news)
def jobs(): jobs = db_session.query(Job).all() return render_template('jobs.html', JOBS=jobs, \ NAV_ACTIVE='jobs')
def news(): newsPosts = reversed(db_session.query(NewsPost).all()) return render_template('news.html', NEWSPOSTS=newsPosts, \ NAV_ACTIVE='news')