Do not add invalid label attribute to input tags.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8564 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang 2012-01-08 17:30:34 +00:00
parent d5a00cc29b
commit f56949af8b
1 changed files with 2 additions and 2 deletions

View File

@ -24,14 +24,14 @@ class Redmine::Views::LabelledFormBuilder < ActionView::Helpers::FormBuilder
%w(date_select)).each do |selector| %w(date_select)).each do |selector|
src = <<-END_SRC src = <<-END_SRC
def #{selector}(field, options = {}) def #{selector}(field, options = {})
label_for_field(field, options) + super label_for_field(field, options) + super(field, options.except(:label))
end end
END_SRC END_SRC
class_eval src, __FILE__, __LINE__ class_eval src, __FILE__, __LINE__
end end
def select(field, choices, options = {}, html_options = {}) def select(field, choices, options = {}, html_options = {})
label_for_field(field, options) + super label_for_field(field, options) + super(field, choices, options, html_options.except(:label))
end end
# Returns a label tag for the given field # Returns a label tag for the given field