A corporation manager and dashboard for EVE Online

_header.html.erb 841 B

12345678910111213141516171819202122232425
  1. <header>
  2. <div id="corp-banner">
  3. <%= link_to(root_url) do %>
  4. <%= corp_logo_tag %>
  5. <span><%= AdminSetting.get(:corp_name) %></span>
  6. <% end %>
  7. </div>
  8. <nav>
  9. <ul>
  10. <% if @user %>
  11. <li><%= @user.name %> [<%= Calefaction::EVE.corp_ticker @user.corp_id %>]</li>
  12. <% if @user.admin? %>
  13. <li><%= link_to 'Admin', controller: 'admin', action: 'index' %></li>
  14. <% end %>
  15. <li><%= link_to 'Logout', {controller: 'users', action: 'logout'}, method: :post %></li>
  16. <% else %>
  17. <li><%= link_to 'Login', controller: 'users', action: 'login' %></li>
  18. <li><%= link_to 'Signup', controller: 'users', action: 'signup' %></li>
  19. <% end %>
  20. </ul>
  21. </nav>
  22. </header>
  23. <% flash.each do |type, message| %>
  24. <div class="flash <%= type %>"><%= message %></div>
  25. <% end %>