Rename duplicate dom id; fixes #1823

closes #1935
This commit is contained in:
Toks
2013-08-14 13:13:14 -04:00
parent 4fd598c098
commit ab4196a0e3
2 changed files with 5 additions and 5 deletions

View File

@@ -54,10 +54,10 @@ class PostsController < ApplicationController
if @post.errors.any?
@error_message = @post.errors.full_messages.join("; ")
render :template => "static/error", :status => 500
elsif params[:tags].present? && params[:pool_id].present?
redirect_to post_path(@post, :tags => params[:tags], :pool_id => params[:pool_id])
elsif params[:tags].present?
redirect_to post_path(@post, :tags => params[:tags])
elsif params[:tags_query].present? && params[:pool_id].present?
redirect_to post_path(@post, :tags => params[:tags_query], :pool_id => params[:pool_id])
elsif params[:tags_query].present?
redirect_to post_path(@post, :tags => params[:tags_query])
elsif params[:pool_id].present?
redirect_to post_path(@post, :pool_id => params[:pool_id])
else

View File

@@ -5,7 +5,7 @@
<% end %>
<%= form_for(post, :html => {:class => "simple_form", :id => "form"}) do |f| %>
<%= hidden_field_tag :tags, params[:tags] %>
<%= hidden_field_tag :tags_query, params[:tags] %>
<%= hidden_field_tag :pool_id, params[:pool_id] %>
<%= f.hidden_field :old_tag_string, :value => post.tag_string %>