ActionView::Template::Error (undefined method `description' for #<VersionCustomField:

Added by Alexander Muthmann about 6 years ago

Hi,

I just tried to create a custom field of type "version" which used to work the last time I tried. This time, I just get an Internal Server Error and the attached Log.

I currently don't have any plugin installed and you can find the versions attached below.

The error occurs on each page, which uses a custom field (also old custom field, e.g. in the "new issue" dialog) but also if I try to delete a custom field.

Started GET "/redmine/custom_fields/new?utf8=%E2%9C%93&type=VersionCustomField" for XXX.XXX.XXX.XXX at 2014-06-04 09                  :46:02 +0200
Processing by CustomFieldsController#new as HTML
  Parameters: {"utf8"=>"✓", "type"=>"VersionCustomField"}
  Current user: deveth0 (id=3)
  Rendered custom_fields/_form.html.erb (4.4ms)
  Rendered custom_fields/new.html.erb within layouts/admin (7.2ms)
Completed 500 Internal Server Error in 48.7ms

ActionView::Template::Error (undefined method `description' for #<VersionCustomField:0xb6784b8>):
    4: <div class="box tabular">
    5: <p><%= f.select :field_format, custom_field_formats_for_select(@custom_field), {}, :disabled => !@custom_fie                  ld.new_record? %></p>
    6: <p><%= f.text_field :name, :required => true %></p>
    7: <p><%= f.text_area :description, :rows => 7 %></p>
    8:
    9: <% if @custom_field.format.multiple_supported %>
    10: <p>
  lib/redmine/views/labelled_form_builder.rb:31:in `text_area'
  app/views/custom_fields/_form.html.erb:7:in `_app_views_custom_fields__form_html_erb___352399386__637698298'
  app/views/custom_fields/new.html.erb:6:in `block in _app_views_custom_fields_new_html_erb___300723749_96322570'
  app/helpers/application_helper.rb:1042:in `labelled_form_for'
  app/views/custom_fields/new.html.erb:5:in `_app_views_custom_fields_new_html_erb___300723749_96322570'


Environment:
  Redmine version                2.5.1.stable
  Ruby version                   2.0.0-p457 (2014-03-03) [i386-linux-gnu]
  Rails version                  3.2.17
  Environment                    production
  Database adapter               Mysql2
SCM:
  Subversion                     1.8.9
  Git                            2.0.0
  Filesystem                     
Y

Replies (1)

RE: ActionView::Template::Error (undefined method `description' for #<VersionCustomField: - Added by Alexander Muthmann about 6 years ago

Oh, I should have had a look at the tickets first, sry.

The fix: #16493

(1-1/1)