% add_to_page_title "Outpost" %>
<%= page_title %>
<%= stylesheet_link_tag "outpost/application" %> <%= javascript_include_tag "outpost/application" %>
<%= csrf_meta_tags %>
Outpost
<% if current_user %>
Navigation
<% models = current_user.allowed_resources.sort_by(&:name) %> <% per_col = 20 %> <% cols = (models.size.to_f / per_col.to_f).ceil %>
<% models.each_with_index do |model, index| %> <% if index % per_col == 0 %>
<% end %>
<%= model.name.titleize.pluralize %>
<% if model.respond_to?(:admin_new_path) %>
Add
<% end %>
<% if index % per_col == per_col - 1 or model == models.last %>
<% end %> <% end %>
<%= current_user.name %>
<%= link_to "Logout", outpost_logout_path, id: "logout" %>
<% else %>
<%= link_to "Login", outpost_login_path %>
<% end %>
<% if current_user %>
<% if breadcrumbs.present? %>
<%= render_breadcrumbs %>
<% end %>
<% end %>
"> <%= render_flash_messages %> <%= yield %>
<% if content_for?(:sidebar) %>
<%= yield :sidebar %>
<% end %>
<%= yield :footer %>