Sha256: 5b4652e18c2fc72745c62f16072bd309d22c6ac88ac35b4cc78c215030c158ac

Contents?: true

Size: 588 Bytes

Versions: 125

Compression:

Stored size: 588 Bytes

Contents

<%
        
def category_list(cat)  
  str = "<ul>"
  str << category_list_items(cat)
  str << "</ul>"
  return str
end
      
def category_list_items(cat)     
  str = "<li><a href='/admin/categories/#{cat.id}'>#{cat.name}</a>"        
  cat.children.each{ |kid| str << category_list(kid) } if cat.children && cat.children.count > 0    
  str << "</li>"
  return str
end
    
%>

<h1>Categories</h1>
<a class="caboose-btn" href='/admin/categories/new'>New Category</a>
<%= category_list(@top_cat) %>

<% content_for :caboose_js do %>
<script type='text/javascript'>
	
</script>
<% end %>

Version data entries

125 entries across 125 versions & 1 rubygems

Version Path
caboose-cms-0.9.229 app/views/caboose/categories/admin_index.html.erb
caboose-cms-1.0.2 app/views/caboose/categories/admin_index.html.erb
caboose-cms-1.0.1 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.228 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.227 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.226 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.225 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.224 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.223 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.222 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.221 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.220 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.219 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.218 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.217 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.216 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.215 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.214 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.213 app/views/caboose/categories/admin_index.html.erb
caboose-cms-0.9.212 app/views/caboose/categories/admin_index.html.erb