schema change; added flask-login
This commit is contained in:
parent
3f867b4027
commit
a646c96b86
8 changed files with 100 additions and 74 deletions
|
|
@ -12,14 +12,14 @@
|
|||
<div class="header">
|
||||
<h1><a href="{{ url_for('homepage') }}">{{ site_name }}</a></h1>
|
||||
<div class="metanav">
|
||||
{% if not session.logged_in %}
|
||||
{% if current_user.is_anonymous %}
|
||||
<a href="{{ url_for('login') }}">log in</a>
|
||||
<a href="{{ url_for('register') }}">register</a>
|
||||
{% else %}
|
||||
<a href="{{ url_for('user_detail', username=current_user.username) }}">{{ current_user.username }}</a>
|
||||
{% set notification_count = current_user.unseen_notification_count() %}
|
||||
{% if notification_count > 0 %}
|
||||
<a href="{{ url_for('notifications') }}">({{ notification_count }})</a>
|
||||
<a href="{{ url_for('notifications') }}">(<strong>{{ notification_count }}</strong>)</a>
|
||||
{% endif %}
|
||||
-
|
||||
<a href="{{ url_for('public_timeline') }}">explore</a>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue