diff --git a/app/controllers/admin/feedback_controller.rb b/app/controllers/admin/feedback_controller.rb index a262c3fb71..b45ffe5559 100644 --- a/app/controllers/admin/feedback_controller.rb +++ b/app/controllers/admin/feedback_controller.rb @@ -107,7 +107,8 @@ def bulkops items = Feedback.find(ids) @unexpired = true - case params[:bulkop] + bulkop = params[:bulkop_top].empty? ? params[:bulkop_bottom] : params[:bulkop_top] + case bulkop when 'Delete Checked Items' count = 0 ids.each do |id| diff --git a/app/models/sidebar.rb b/app/models/sidebar.rb index 1925ce38af..9df3b78bd6 100644 --- a/app/models/sidebar.rb +++ b/app/models/sidebar.rb @@ -74,8 +74,8 @@ def value_for(choice) class CheckBoxField < self def input_html(sidebar) - check_box_tag(input_name(sidebar), 1, sidebar.config[key], options)+ - hidden_field_tag(input_name(sidebar),0) + hidden_field_tag(input_name(sidebar),0)+ + check_box_tag(input_name(sidebar), 1, sidebar.config[key], options) end def line_html(sidebar) diff --git a/app/views/admin/feedback/_button.html.erb b/app/views/admin/feedback/_button.html.erb index 14712f8e4a..7f1d8680e7 100644 --- a/app/views/admin/feedback/_button.html.erb +++ b/app/views/admin/feedback/_button.html.erb @@ -1,7 +1,7 @@
<%= hidden_field_tag "confirmed", params[:confirmed] %> <%= hidden_field_tag "published", params[:published] %> - <%= hidden_field_tag "bulkop", "",{:id=>"bulkop"} %> + <%= hidden_field_tag "bulkop_#{position}", "",{:id=>"bulkop"} %> <%= submit_tag _("Delete Checked Items"), {:class => 'submit',:onclick=>"getElementById('bulkop').value='Delete Checked Items'"} %> <%= submit_tag _("Mark Checked Items as Ham"), {:class => 'submit',:onclick=>"getElementById('bulkop').value='Mark Checked Items as Ham'"} %> <%= submit_tag _("Mark Checked Items as Spam"), {:class => 'submit',:onclick=>"getElementById('bulkop').value='Mark Checked Items as Spam'"} %> diff --git a/app/views/admin/feedback/index.html.erb b/app/views/admin/feedback/index.html.erb index 7925462576..c78abb47b9 100644 --- a/app/views/admin/feedback/index.html.erb +++ b/app/views/admin/feedback/index.html.erb @@ -11,7 +11,7 @@