<% if cuser.admin? %>
-
<%= link_to '/about/adminpanel', class: 'admin' do %>
Admin (<%= Issue.with_status(0).count %>) <%= icon 'wrench' %>
<% end %>
<% elsif cuser.moderator? %>
-
<%= link_to issues_path, class: 'admin' do %>
Issues (<%= Issue.where(category_id: Issue.allowed_categories(cuser)).with_status(0).count %>) <%= icon 'wrench' %>
<% end %>
<% end %>
-
<%= link_to user_path(cuser) do %>
Account <%= icon 'user' %>
<% end %>
-
<%= link_to "/users/agenda/#{cuser.id}" do %>
Agenda <%= icon 'calendar' %>
<% end %>
-
<%= link_to messages_path do %>
Messages <%= icon 'envelope' %>
<% end %>
<% if c = cuser.new_messages.count > 0 %>
(<%= cuser.new_messages.count %>)
<% end %>
-
<%= form_tag(controller: 'users', action: 'logout') do %>
<%= link_to '#', id: 'logout' do %>
Logout <%= icon 'key' %>
<% end %>
<% end %>
<% if cuser.profile %>
<% end %>