aboutsummaryrefslogtreecommitdiffstats
path: root/app/views/admin/blog/posts
diff options
context:
space:
mode:
authorPhilip Arndt <parndt@gmail.com>2010-08-25 16:15:02 +1200
committerPhilip Arndt <parndt@gmail.com>2010-08-25 16:15:02 +1200
commit11f16cd66e86396bda09e3bdede88fd08f35bc1c (patch)
tree9bef7375acf9fc9b79865ff23d42ca0f823e6182 /app/views/admin/blog/posts
parent4fbe3219386f68654ffaf123e30a219b4959de78 (diff)
downloadrefinerycms-blog-11f16cd66e86396bda09e3bdede88fd08f35bc1c.tar.gz
refinerycms-blog-11f16cd66e86396bda09e3bdede88fd08f35bc1c.tar.bz2
refinerycms-blog-11f16cd66e86396bda09e3bdede88fd08f35bc1c.zip
Added categories section
Diffstat (limited to 'app/views/admin/blog/posts')
-rw-r--r--app/views/admin/blog/posts/_form.html.erb20
1 files changed, 15 insertions, 5 deletions
diff --git a/app/views/admin/blog/posts/_form.html.erb b/app/views/admin/blog/posts/_form.html.erb
index a03ff82..da3f132 100644
--- a/app/views/admin/blog/posts/_form.html.erb
+++ b/app/views/admin/blog/posts/_form.html.erb
@@ -24,11 +24,14 @@
<div id='more_options' style="display:none;">
<div class="hemisquare">
<h3><%= t('admin.blog.submenu.categories.title') %></h3>
- <ul class='categories'>
- <% @blog_categories.each do |category| %>
- <li>
- checkboxes for category <%= category.title %>
- </li>
+ <ul class='blog_categories'>
+ <% f.fields_for :categories do |c| %>
+ <% @blog_categories.each do |category| %>
+ <li>
+ <%= c.check_box :id, :value => category.id %>
+ <%= c.label :id, category.title, :class => 'stripped' %>
+ </li>
+ <% end %>
<% end %>
</ul>
</div>
@@ -43,6 +46,13 @@
} %>
<% end -%>
<% content_for :head do %>
+ <style type='text/css'>
+ ul.blog_categories, ul.blog_categories li {
+ list-style: none;
+ margin: 0px;
+ padding: 0px;
+ }
+ </style>
<script type='text/javascript'>
$(document).ready(function(){
$('#toggle_advanced_options').click(function(e){