Fix #4458: Duplicate HTML IDs on post show page.
This commit is contained in:
@@ -7,9 +7,9 @@
|
||||
<%= render "sources/info" %>
|
||||
|
||||
<%= edit_form_for(post, html: { id: "form" }) do |f| %>
|
||||
<%= hidden_field_tag :tags_query, params[:q] %>
|
||||
<%= hidden_field_tag :pool_id, params[:pool_id] %>
|
||||
<%= hidden_field_tag :favgroup_id, params[:favgroup_id] %>
|
||||
<%= f.input :tags_query, as: :hidden, input_html: { id: nil, name: "tags_query", value: params[:q] } %>
|
||||
<%= f.input :pool_id, as: :hidden, input_html: { id: nil, name: "pool_id", value: params[:pool_id] } %>
|
||||
<%= f.input :favgroup_id, as: :hidden, input_html: { id: nil, name: "favgroup_id", value: params[:favgroup_id] } %>
|
||||
<%= f.input :old_tag_string, as: :hidden, input_html: { value: post.tag_string } %>
|
||||
<%= f.input :old_parent_id, as: :hidden, input_html: { value: post.parent_id } %>
|
||||
<%= f.input :old_source, as: :hidden, input_html: { value: post.source } %>
|
||||
|
||||
@@ -61,25 +61,17 @@
|
||||
<% end %>
|
||||
|
||||
<section id="mark-as-translated-section" style="display: none;">
|
||||
<%= form_tag(mark_as_translated_post_path(@post), :class => "simple_form", :method => :put) do |f| %>
|
||||
<%= hidden_field_tag :tags_query, params[:q] %>
|
||||
<%= hidden_field_tag :pool_id, params[:pool_id] %>
|
||||
<%= edit_form_for(@post, url: mark_as_translated_post_path(@post), method: :put) do |f| %>
|
||||
<%= f.input :tags_query, as: :hidden, input_html: { id: nil, name: "tags_query", value: params[:q] } %>
|
||||
<%= f.input :pool_id, as: :hidden, input_html: { id: nil, name: "pool_id", value: params[:pool_id] } %>
|
||||
<%= f.input :favgroup_id, as: :hidden, input_html: { id: nil, name: "favgroup_id", value: params[:favgroup_id] } %>
|
||||
|
||||
<fieldset>
|
||||
<label for="post_check_translation">
|
||||
<%= check_box "post", "check_translation", :checked => @post.has_tag?("check_translation") %>
|
||||
Check translation
|
||||
</label>
|
||||
|
||||
<label for="post_partially_translated">
|
||||
<%= check_box "post", "partially_translated", :checked => @post.has_tag?("partially_translated") %>
|
||||
Partially translated
|
||||
</label>
|
||||
<fieldset class="inline-fieldset">
|
||||
<%= f.input :check_translation, as: :boolean, input_html: { checked: @post.has_tag?("check_translation") } %>
|
||||
<%= f.input :partially_translated, as: :boolean, input_html: { checked: @post.has_tag?("partially_translated") } %>
|
||||
</fieldset>
|
||||
|
||||
<div class="input">
|
||||
<%= submit_tag "Mark as translated" %>
|
||||
</div>
|
||||
<%= f.submit "Mark as translated" %>
|
||||
<% end %>
|
||||
</section>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user