2014-04-29 23:34:48 +00:00
|
|
|
<div class="logged">
|
|
|
|
<div class="links">
|
|
|
|
<ul>
|
|
|
|
<% if cuser.admin? %>
|
|
|
|
<li>
|
|
|
|
<%= link_to '/about/adminpanel', class: 'admin' do %>
|
|
|
|
Admin (<%= Issue.with_status(0).count %>) <%= icon 'wrench' %>
|
|
|
|
<% end %>
|
|
|
|
</li>
|
2017-06-24 18:43:42 +00:00
|
|
|
<% elsif cuser.moderator? %>
|
|
|
|
<li>
|
|
|
|
<%= link_to issues_path, class: 'admin' do %>
|
|
|
|
Issues (<%= Issue.where(category_id: Issue.allowed_categories(cuser)).with_status(0).count %>) <%= icon 'wrench' %>
|
|
|
|
<% end %>
|
|
|
|
</li>
|
2014-04-29 23:34:48 +00:00
|
|
|
<% end %>
|
2014-04-19 01:12:02 +00:00
|
|
|
<li>
|
2015-08-24 15:02:55 +00:00
|
|
|
<%= link_to user_path(cuser) do %>
|
2014-04-29 23:34:48 +00:00
|
|
|
Account <%= icon 'user' %>
|
2014-04-19 01:12:02 +00:00
|
|
|
<% end %>
|
|
|
|
</li>
|
2014-04-29 23:34:48 +00:00
|
|
|
<li>
|
|
|
|
<%= link_to "/users/agenda/#{cuser.id}" do %>
|
|
|
|
Agenda <%= icon 'calendar' %>
|
2014-04-08 23:28:46 +00:00
|
|
|
<% end %>
|
2014-04-29 23:34:48 +00:00
|
|
|
</li>
|
|
|
|
<li>
|
|
|
|
<%= link_to messages_path do %>
|
|
|
|
Messages <%= icon 'envelope' %>
|
|
|
|
<% end %>
|
|
|
|
<% if c = cuser.new_messages.count > 0 %>
|
|
|
|
(<%= cuser.new_messages.count %>)
|
|
|
|
<% end %>
|
|
|
|
</li>
|
|
|
|
<li>
|
2014-05-02 16:43:23 +00:00
|
|
|
<%= form_tag(controller: 'users', action: 'logout') do %>
|
|
|
|
<%= link_to '#', id: 'logout' do %>
|
2014-04-29 23:34:48 +00:00
|
|
|
Logout <%= icon 'key' %>
|
|
|
|
<% end %>
|
|
|
|
<% end %>
|
|
|
|
</li>
|
|
|
|
</ul>
|
|
|
|
</div>
|
2014-04-08 23:28:46 +00:00
|
|
|
|
2014-05-11 12:00:09 +00:00
|
|
|
<% if cuser.profile %>
|
|
|
|
<div class="avatar" style="background-image: url('<%= cuser.profile.avatar.url %>')"></div>
|
|
|
|
<% end %>
|
2014-04-29 23:34:48 +00:00
|
|
|
</div>
|