Project 'mj/mo-submit' was moved to 'mo-p/osmo'. Please update any links and bookmarks that may still have the old path.
Select Git revision

Martin Mareš authored
misc.py 420 B
from flask import render_template, redirect, url_for, g
from mo.web import app
@app.route('/')
def index():
"""Titulní stránka, která přihlášené uživatele přesměruje do jejich sekce."""
if g.user:
if g.user.is_admin or g.user.is_org:
return redirect(url_for('org_index'))
else:
return redirect(url_for('user_index'))
return render_template('main.html')