|
|
|
@ -23,13 +23,15 @@
|
|
|
|
|
<a class="item<% if (active === 'help') { %> active<% } %>" href="/help"><i class="help circle icon"></i> 帮助</a> |
|
|
|
|
<div class="right menu"> |
|
|
|
|
<% if (user) { %> |
|
|
|
|
<div class="ui simple dropdown item" onclick="location.href = '<%= syzoj.utils.makeUrl(['user', user.id]) %>'"> |
|
|
|
|
<a href="<%= syzoj.utils.makeUrl(['user', user.id]) %>" style="color: inherit; "> |
|
|
|
|
<div class="ui simple dropdown item"> |
|
|
|
|
<%= user.username %> <i class="dropdown icon"></i> |
|
|
|
|
<div class="menu"> |
|
|
|
|
<a class="item" href="<%= syzoj.utils.makeUrl(['user', user.id, 'edit']) %>"><i class="edit icon"></i>修改资料</a> |
|
|
|
|
<a class="item" href="#" id="logout"><i class="power icon"></i>注销</a> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
</a> |
|
|
|
|
<% } else { %> |
|
|
|
|
<div class="item"> |
|
|
|
|
<div class="ui button" style="margin-right: 0.5em" onclick="window.location.href='/login'"> |
|
|
|
|