mirror of
https://github.com/QingdaoU/OnlineJudge.git
synced 2025-11-04 14:49:58 +08:00
为超级管理员添加前台到后台的链接
This commit is contained in:
parent
6c07396cea
commit
0bbd4a1a06
@ -50,28 +50,31 @@
|
|||||||
<li><a href="/about/">关于</a></li>
|
<li><a href="/about/">关于</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
{% if request.user.is_authenticated %}
|
{% if request.user.is_authenticated %}
|
||||||
<ul class="nav navbar-nav navbar-right">
|
<ul class="nav navbar-nav navbar-right">
|
||||||
<li class="dropdown">
|
<li class="dropdown">
|
||||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true"
|
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true"
|
||||||
aria-expanded="false">
|
aria-expanded="false">
|
||||||
{{ request.user.username }}
|
{{ request.user.username }}
|
||||||
<span class="caret"></span></a>
|
<span class="caret"></span></a>
|
||||||
<ul class="dropdown-menu">
|
<ul class="dropdown-menu">
|
||||||
<li><a href="/submissions/">我的提交</a></li>
|
{% if request.user.admin_type == 2 %}
|
||||||
<li><a href="#">我的资料</a></li>
|
<li><a href="/admin/">后台管理</a></li>
|
||||||
<li role="separator" class="divider"></li>
|
{% endif %}
|
||||||
<li><a href="/logout/">退出</a></li>
|
<li><a href="/submissions/">我的提交</a></li>
|
||||||
</ul>
|
<li><a href="#">我的资料</a></li>
|
||||||
</li>
|
<li role="separator" class="divider"></li>
|
||||||
</ul>
|
<li><a href="/logout/">退出</a></li>
|
||||||
|
</ul>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
{% else %}
|
{% else %}
|
||||||
<ul class="nav navbar-nav navbar-right">
|
<ul class="nav navbar-nav navbar-right">
|
||||||
<li>
|
<li>
|
||||||
<a href="/login/">
|
<a href="/login/">
|
||||||
登录
|
登录
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user