Renamed TabularFormBuilder to Redmine::Views::LabelledFormBuilder.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8143 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
ede9a03405
commit
877fbc15da
|
@ -871,28 +871,28 @@ module ApplicationHelper
|
||||||
options = args.last
|
options = args.last
|
||||||
options[:html] ||= {}
|
options[:html] ||= {}
|
||||||
options[:html][:class] = 'tabular' unless options[:html].has_key?(:class)
|
options[:html][:class] = 'tabular' unless options[:html].has_key?(:class)
|
||||||
options.merge!({:builder => TabularFormBuilder})
|
options.merge!({:builder => Redmine::Views::LabelledFormBuilder})
|
||||||
form_for(*args, &proc)
|
form_for(*args, &proc)
|
||||||
end
|
end
|
||||||
|
|
||||||
def labelled_form_for(*args, &proc)
|
def labelled_form_for(*args, &proc)
|
||||||
args << {} unless args.last.is_a?(Hash)
|
args << {} unless args.last.is_a?(Hash)
|
||||||
options = args.last
|
options = args.last
|
||||||
options.merge!({:builder => TabularFormBuilder})
|
options.merge!({:builder => Redmine::Views::LabelledFormBuilder})
|
||||||
form_for(*args, &proc)
|
form_for(*args, &proc)
|
||||||
end
|
end
|
||||||
|
|
||||||
def labelled_fields_for(*args, &proc)
|
def labelled_fields_for(*args, &proc)
|
||||||
args << {} unless args.last.is_a?(Hash)
|
args << {} unless args.last.is_a?(Hash)
|
||||||
options = args.last
|
options = args.last
|
||||||
options.merge!({:builder => TabularFormBuilder})
|
options.merge!({:builder => Redmine::Views::LabelledFormBuilder})
|
||||||
fields_for(*args, &proc)
|
fields_for(*args, &proc)
|
||||||
end
|
end
|
||||||
|
|
||||||
def labelled_remote_form_for(*args, &proc)
|
def labelled_remote_form_for(*args, &proc)
|
||||||
args << {} unless args.last.is_a?(Hash)
|
args << {} unless args.last.is_a?(Hash)
|
||||||
options = args.last
|
options = args.last
|
||||||
options.merge!({:builder => TabularFormBuilder})
|
options.merge!({:builder => Redmine::Views::LabelledFormBuilder})
|
||||||
remote_form_for(*args, &proc)
|
remote_form_for(*args, &proc)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -17,7 +17,7 @@
|
||||||
|
|
||||||
require 'action_view/helpers/form_helper'
|
require 'action_view/helpers/form_helper'
|
||||||
|
|
||||||
class TabularFormBuilder < ActionView::Helpers::FormBuilder
|
class Redmine::Views::LabelledFormBuilder < ActionView::Helpers::FormBuilder
|
||||||
include Redmine::I18n
|
include Redmine::I18n
|
||||||
|
|
||||||
(field_helpers.map(&:to_s) - %w(radio_button hidden_field fields_for) +
|
(field_helpers.map(&:to_s) - %w(radio_button hidden_field fields_for) +
|
Loading…
Reference in New Issue