mirror of
https://gitlab.ub.uni-bielefeld.de/sfb1288inf/nopaque.git
synced 2024-12-25 10:54:18 +00:00
Add api and administration links to navigations
This commit is contained in:
parent
713a7645db
commit
1372c86609
@ -56,5 +56,24 @@
|
|||||||
Log out
|
Log out
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
{% if current_user.can('USE_API') or current_user.is_administrator %}
|
||||||
|
<li class="divider" tabindex="-1"></li>
|
||||||
|
{% endif %}
|
||||||
|
{% if current_user.can('USE_API') %}
|
||||||
|
<li>
|
||||||
|
<a href="{{ url_for('apifairy.docs') }}">
|
||||||
|
<i class="material-icons left">api</i>
|
||||||
|
API
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
{% endif %}
|
||||||
|
{% if current_user.is_administrator %}
|
||||||
|
<li {% if request.path == url_for('admin.admin') %}class="active"{% endif %}>
|
||||||
|
<a href="{{ url_for('admin.admin') }}">
|
||||||
|
<i class="material-icons left">admin_panel_settings</i>
|
||||||
|
Administration
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
{% endif %}
|
||||||
</ul>
|
</ul>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
@ -105,19 +105,21 @@
|
|||||||
</li>
|
</li>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if current_user.is_authenticated and current_user.can('ADMINISTRATE') %}
|
{% if current_user.can('USE_API') or current_user.is_administrator %}
|
||||||
{# administration section #}
|
|
||||||
<li><div class="divider"></div></li>
|
<li><div class="divider"></div></li>
|
||||||
<li><a class="subheader">Administration</a></li>
|
{% endif %}
|
||||||
|
|
||||||
{# corpora #}
|
{% if current_user.can('USE_API') %}
|
||||||
|
{# API #}
|
||||||
<li>
|
<li>
|
||||||
<a class="waves-effect" href="{{ url_for('admin.corpora') }}"><i class="nopaque-icons">I</i>Corpora</a>
|
<a class="waves-effect" href="{{ url_for('apifairy.docs') }}"><i class="material-icons">api</i>API</a>
|
||||||
</li>
|
</li>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
{# users #}
|
{% if current_user.is_administrator %}
|
||||||
<li>
|
{# Administration #}
|
||||||
<a class="waves-effect" href="{{ url_for('admin.users') }}"><i class="material-icons">manage_accounts</i>Users</a>
|
<li {% if request.path == url_for('admin.admin') %}class="active"{% endif %}>
|
||||||
|
<a class="waves-effect" href="{{ url_for('admin.admin') }}"><i class="material-icons">admin_panel_settings</i>Administration</a>
|
||||||
</li>
|
</li>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</ul>
|
</ul>
|
||||||
|
Loading…
Reference in New Issue
Block a user