cats show up on listings

Oleg committed Aug 24, 2011
commit 643ce7f3c8b7ae5ed6177043f9b46789d97a60f2
Showing 5 changed files with 18 additions and 0 deletions
app/assets/stylesheets/comfortable_mexican_sofa/content.css +9 -0
@@ @@ -195,6 +195,15 @@
font-size: 14px;
font-weight: bold;
}
+ #cms_body ul.list li .item .label span.category {
+ display: inline-block;
+ padding: 2px 5px;
+ font: 9px/9px Arial, sans-serif;
+ background-color: #e0e0e0;
+ border-radius: 3px;
+ text-transform: uppercase;
+ color: #888;
+ }
#cms_body ul.list li .item .label .sublabel {
font-size: 10px;
font-weight: normal;
app/views/cms_admin/categories/_categories.html.erb +6 -0
@@ @@ -0,0 +1,6 @@
+ <% object ||= categories %>
+ <% object.categories.each do |category| %>
+ <span class='category'>
+ <%= category.label %>
+ </span>
+ <% end %>
\ No newline at end of file
app/views/cms_admin/files/index.html.erb +1 -0
@@ @@ -14,6 +14,7 @@
</div>
<div class='label'>
<%= link_to file.label, edit_cms_admin_site_file_path(@site, file) %>
+ <%= render :partial => '/cms_admin/categories/categories', :object => file %>
<div class='sublabel'>
<%= link_to file.file_file_name, file.file.url, :target => '_blank' %>
</div>
app/views/cms_admin/pages/_index_branch.html.erb +1 -0
@@ @@ -26,6 +26,7 @@
</div>
<div class='label'>
<%= link_to page.label, edit_cms_admin_site_page_path(@site, page) %>
+ <%= render :partial => '/cms_admin/categories/categories', :object => page %>
<div class='sublabel'>
<%= link_to page.url, page.full_path, :target => '_blank' %>
</div>
app/views/cms_admin/snippets/index.html.erb +1 -0
@@ @@ -18,6 +18,7 @@
</div>
<div class='label'>
<%= link_to snippet.label, edit_cms_admin_site_snippet_path(@site, snippet) %>
+ <%= render :partial => '/cms_admin/categories/categories', :object => snippet %>
<div class='sublabel'>
<%= link_to snippet.slug, edit_cms_admin_site_snippet_path(@site, snippet) %>
</div>