]> source.dussan.org Git - redmine.git/commitdiff
Custom fields in issue form - splitting is incorrect (#15227).
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Sat, 9 Nov 2013 11:19:06 +0000 (11:19 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Sat, 9 Nov 2013 11:19:06 +0000 (11:19 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@12251 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/views/issues/_form_custom_fields.html.erb

index 4da98eb133119f1123c25ddafaf11011abec2574..6182c28f6cee2635876d88b779bce523b0ec5600 100644 (file)
@@ -1,8 +1,9 @@
+<% custom_field_values = @issue.editable_custom_field_values %>
 <div class="splitcontent">
 <div class="splitcontentleft">
 <% i = 0 %>
-<% split_on = (@issue.custom_field_values.size / 2.0).ceil - 1 %>
-<% @issue.editable_custom_field_values.each do |value| %>
+<% split_on = (custom_field_values.size / 2.0).ceil - 1 %>
+<% custom_field_values.each do |value| %>
   <p><%= custom_field_tag_with_label :issue, value, :required => @issue.required_attribute?(value.custom_field_id) %></p>
 <% if i == split_on -%>
 </div><div class="splitcontentright">